Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including babel-preset-flow with all npm packages installed. Try it out:

var babelPresetFlow = require("babel-preset-flow")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

babel-preset-flow v6.23.0

Babel preset for all Flow plugins.

babel-preset-flow

Babel preset for all Flow plugins.

This preset includes the following plugins:

Example

In

function foo(one: any, two: number, three?): string {}

Out

function foo(one, two, three) {}

Installation

npm install --save-dev babel-preset-flow

Usage

Via .babelrc (Recommended)

.babelrc

{
  "presets": ["flow"]
}

Via CLI

babel --presets flow script.js

Via Node API

require("babel-core").transform("code", {
  presets: ["flow"]
});

Metadata

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free