rollup-plugin-ae-jsx

RollupJS plugin to turn output into After Effects compatible `.jsx` JSON files

Usage no npm install needed!

<script type="module">
  import rollupPluginAeJsx from 'https://cdn.skypack.dev/rollup-plugin-ae-jsx';
</script>

README

npm size

rollup-plugin-ae-jsx

A Rollup plugin which converts the ouput to After Effects compatible JSON for .jsx files.

Requirements

This plugin requires an LTS Node version (v8.0.0+) and Rollup v1.20.0+.

Install

Using npm:

npm install rollup-plugin-ae-jsx --save-dev

Usage

Create a rollup.config.js configuration file, import the plugin, and add it to the plugins array:

import afterEffectJsx from "./rollup-plugin-ae-jsx";

export default {
  input: "src/index.js",
  output: {
    file: "dist/index.jsx",
    format: "cjs",
  },
  plugins: [afterEffectsJsx()],
};
  • The output extension should be .jsx and format cjs to ensure After Effects compatible files.
  • rollup-plugin-ae-jsx should be placed in plugins after any other plugins.

Then call rollup either via the CLI or the API.

Limitations

  • Output code must be in a single file
  • Makes some manual transformations outside of the AST
  • Pretty experimental!

Meta

CONTRIBUTING

LICENSE (MIT)