Skip to content

akbaruddin/js-tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Configure Flow in JavaScript

Setup

Create package.json file

pnpm init -y

Install Babel and Flow bin

pnpm i -D @babel/{cli,core,preset-flow} flow-bin

Create .babelrc file

{
  "presets": ["@babel/preset-flow"]
}

Generate .flowconfig file

pnpx flow init

Check flow error and status

pnpx flow status

Add compile on package.json

"scripts": {
    "build": "babel src/ -d lib/"
},

add @flow on Source file

main.js

// @flow

/**
 * Code
 */

RUN

pnpm build

About

Flow config Sample

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published