fbjs icon indicating copy to clipboard operation
fbjs copied to clipboard

Fix __DEV__ & Flow interaction

Open zpao opened this issue 7 years ago • 0 comments

Ok, there are a couple pieces to this.

  1. Revert the removal of flow/lib/dev.js from #182. We need this for projects consuming fbjs directly & using flow, which will check the raw src files. We probably want it for ourselves too (not currently an issue because the files using __DEV__ are not flowified).
  2. Add an inline declare as part of the Flow transform, inserting declare var __DEV__: boolean; at the top of each file using it.

We can ship 0.8.5 once we have part 1 here done. It's no worse than today (strictly better since the other flow+fbjs issues are resolved). We don't even need part 2 done for fbjs itself (same aside as part 1 above.

zpao avatar Sep 27 '16 22:09 zpao