Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

Use it with a bundler

CP Clermont edited this page May 26, 2022 · 1 revision

Bundlers like webpack, Rollup or browserify automatically recognize how to handle the plugin. Remember that even when using a bundler, you still have to use the standalone builds:

import prettier from 'prettier/standalone';
import liquidPlugin from '@shopify/prettier-plugin-liquid/standalone';

prettier.format(YOUR_CODE, {
  plugins: [liquidPlugin],
  parser: 'liquid-html',
});
Clone this wiki locally