Git Product home page Git Product logo

rollup-plugin-flow's Introduction

Rollup Flow plugin

Build Status

This Rollup plugin will remove Flow type annotations during bundling using flow-remove-types.

Install

npm install --save rollup-plugin-flow
var rollup = require('rollup').rollup;
var flow = require('rollup-plugin-flow');

rollup({
  entry: 'main.js',
  plugins: [ flow() ]
}).then(...);

Options

Provide options as an object argument to flow().

all - Transform all files, not just those containing @flow comments.

Default: false

var flow = require('rollup-plugin-flow');

module.exports = {
  plugins: [ flow({ all: true }) ],
  format: 'cjs'
};

pretty - Remove flow types without replacing them with whitespace.

Default: false

Note: Typically source maps are not necessary for this transform, however source maps are recommended when generating "pretty" results.

var flow = require('rollup-plugin-flow');

module.exports = {
  plugins: [ flow({ pretty: true }) ],
  format: 'cjs'
};

rollup-plugin-flow's People

Contributors

leebyron avatar trysound avatar evenstensberg avatar

Watchers

James Cloos avatar Chenghao Yao avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.