Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gluestick-plugin-no-fouc

Package Overview
Dependencies
Maintainers
4
Versions
91
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gluestick-plugin-no-fouc

Remove FOUC by extracting css into file and linking them to renderer page in development

  • 4.6.6
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
24
increased by26.32%
Maintainers
4
Weekly downloads
 
Created
Source

gluestick-plugin-no-fouc

Removes Flash of Unstyled Content (FOUC) in development.

How it works

All styles will be extracted to a css file using ExtractTextWebpackPlugin then, the file will be linked by server/renderer and added to <head> element. It sits side-by-side with style-loader, so you can still use HMR.

In production this plugin does nothing.

How to use

  • Install plugin
npm install --save gluestick-plugin-no-fouc
  • Define (and configure) plugin in src/gluestick.plugins.js:
export default [
  'gluestick-plugin-no-fouc'
]

// or

export default [
  {
    plugin: 'gluestick-plugin-no-fouc',
    options: {
      filename: '[name].fouc-reducer.css'
    },
  },
]

Configuration

  • filename: string (default: [name]-[contenthash].init-no-fouc.css) - name of the file to which all styles will be extracted, can contain webpack tokens eg: [name], [hash], [contenthash] and so on

FAQs

Package last updated on 27 Mar 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc