Coder Social home page Coder Social logo

Comments (12)

acdlite avatar acdlite commented on July 28, 2024

I would love to use Flow, but need to wait for more complete ES6 support. facebook/flow#62

from flummox.

emmenko avatar emmenko commented on July 28, 2024

👍

from flummox.

chicoxyzzy avatar chicoxyzzy commented on July 28, 2024

as far as I know Babel supports Flow annotations

from flummox.

acdlite avatar acdlite commented on July 28, 2024

Babel will strip the annotations, but Flow itself doesn't support certain ES6 features, so type-checking won't work.

from flummox.

chicoxyzzy avatar chicoxyzzy commented on July 28, 2024

there is a way to blacklist flow transformer babel/babel#665 (comment)

from flummox.

acdlite avatar acdlite commented on July 28, 2024

Huh? Then what's the point?

from flummox.

chicoxyzzy avatar chicoxyzzy commented on July 28, 2024

to run Flow on transpiled ES5 code with Flow annotations in it

from flummox.

acdlite avatar acdlite commented on July 28, 2024

Ah, I see. So we would output the ES5 code to a directory called flow or something, and anyone who wants to use it would do require('flummox/flow') instead of require('flummox')?

from flummox.

chicoxyzzy avatar chicoxyzzy commented on July 28, 2024

yep

from flummox.

acdlite avatar acdlite commented on July 28, 2024

I like that idea. Do you know of any other libraries that are doing this? I've only played with Flow a bit, and I wonder if it would choke on any of extra code Babel adds.

from flummox.

chicoxyzzy avatar chicoxyzzy commented on July 28, 2024

actually no but I saw some people speak about this on babel's gitter channel. I think all should work except runtime will be untyped.
cc @sebmck

from flummox.

sebmck avatar sebmck commented on July 28, 2024

@chicoxyzzy No idea how or why people use it. But Flow should accept and run all Babel ES5 output without a problem and if it doesn't then it'd be a bug in Flow.

from flummox.

Related Issues (20)

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.