0.4.2 • Published 6 years ago

postxml-amp v0.4.2

Weekly downloads
14
License
MIT
Repository
github
Last release
6 years ago

postxml-amp

npm version Downloads Stats

Build Status tested with jest Known Vulnerabilities Greenkeeper badge

PostXML plugin to convert plain HTML to Google Accelerated Mobile Pages (AMP).

Installation

npm install postxml-amp --save

Usage

Postxml

Options

cwd

Assets (images/styles) file path

  • Type: String
  • Default: ''

round

Enable images dimensions rounding

  • Type: String
  • Default: true

Example

Input

<html>
  <head>
    <link rel="stylesheet" href="style.css">
  </head>
  <img src="image.png">
</html>

image.png

image.png

style.css

body {
  background-color: #fff;
}

Output

<html amp="">
  <head>
    <style amp-custom="">body{background-color:#fff}</style>
  </head>
  <amp-img src="image.png" width="600" height="400"></amp-img>
</html>

Release History

HISTORY

Licence

MIT (c) Ruslan Kazakov

0.4.2

6 years ago

0.4.0

6 years ago

0.3.0

6 years ago

0.2.6

7 years ago

0.2.4

8 years ago

0.2.3

8 years ago

0.2.2

8 years ago

0.2.1

8 years ago

0.2.0

8 years ago

0.1.0

8 years ago