Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

mdcollab/flowcheck-loader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

14 Commits

Repository files navigation

flowcheck-loader

This is a Webpack loader for Flowcheck .

Flowcheck is a runtime assertions library that uses Flow syntax but is meant to be ran in development.

npm install --save-dev flowcheck-loader

Chain this loader with jsx?stripTypes so types are stripped in JS code:

// Webpack config
module.exports = {
 ...
 module: {
 loaders: [
 { test: /\.jsx?$/, loaders: ['jsx?harmony&stripTypes', 'flowcheck'], exclude: /node_modules/ }
 ]
 }
};

For production builds, just leave flowcheck out so jsx?stripTypes strips them completely.

You can use this with or without using Flow or TypeScript itself.
It can also be a nice first step towards migrating code to Flow.

Read more about Flowcheck

About

A Webpack loader for Flowcheck

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%

AltStyle によって変換されたページ (->オリジナル) /