Skip to content

Transforms

Björn Schmidtke edited this page May 19, 2017 · 2 revisions

You want to write components in another language? Not JavaScript? Possible.

This is only one thing you can use transforms to. A detailed description will follow. You can write your own transforms.

Use a transform

  • Install or create a transform.
  • Include the transform in your pack and serve commands. Using -t [ some-transform ] (normally the serve, prebuild and postbuild scripts in the package.json).
  • Create a component in /components and enjoy!

Currently existing transforms

  • Install it via npm i -S penguin-pug-transform.
  • Activate it in your pack and serve commands, using -t [ penguin-pug-transform ].
  • Now you can create pug templates of the following filename scheme: components/.pug More info here

Write your own transform

This documentation will follow. For now, check the penguin-pug-transform and write your own. If you have a /some-transform.js in your project, you can use it via -t [ ./some-transform ].

Clone this wiki locally