0.3.0 • Published 3 years ago

@notiz/scully-plugin-fouc v0.3.0

Weekly downloads
15
License
MIT
Repository
github
Last release
3 years ago

scully-plugin-fouc

npm version

scully-plugin-fouc is a postRenderer plugin for Scully to prevent flash of unstyled content.

📦 Installation

To install this plugin with npm run

$ npm install @notiz/scully-plugin-fouc --save-dev

Usage

Add the plugin to the defaultPostRenderers in your scully.config:

require("@notiz/scully-plugin-fouc");

exports.config = {
  projectRoot: "./src/app",
  defaultPostRenderers: ["fouc"],
  routes: {}
};

If you want to use the plugin for a specific route do:

require('@notiz/scully-plugin-fouc');

exports.config = {
  ...
  routes: {
    '/blog/:slug': {
      type: 'contentFolder',
      slug: {
        folder: './content/blog'
      },
      postRenderers: ['fouc']
    }
  }
  ...
};
0.3.0

3 years ago

0.2.0

4 years ago

0.1.0

4 years ago