npm babylon 6.14.0
v6.14.0

latest releases: 7.0.0-beta.47, 7.0.0-beta.46, 7.0.0-beta.45...
7 years ago

6.14.0 (2016-11-16)

๐Ÿ‘“ Spec Compliancy

Throw error for reserved words enum and await (#195) (Kai Cataldo)

11.6.2.2 Future Reserved Words

Babylon will throw for more reserved words such as enum or await (in strict mode).

class enum {} // throws
class await {} // throws in strict mode (module)

Optional names for function types and object type indexers (#197) (Gabe Levi)

So where you used to have to write

type A = (x: string, y: boolean) => number;
type B = (z: string) => number;
type C = { [key: string]: number };

you can now write (with flow 0.34.0)

type A = (string, boolean) => number;
type B = string => number;
type C = { [string]: number };

Parse flow nested array type annotations like number[][] (#219) (Bernhard Hรคussner)

Supports these form now of specifying array types:

var a: number[][][][];
var b: string[][];

๐Ÿ› Bug Fix

Correctly eat semicolon at the end of DelcareModuleExports (#223) (Daniel Tschinder)

declare module "foo" { declare module.exports: number } 
declare module "foo" { declare module.exports: number; }  // also allowed now

๐Ÿ  Internal

  • Count Babel tests towards Babylon code coverage (#182) (Moti Zilberman)
  • Fix strange line endings (#214) (Thomas Grainger)
  • Add node 7 (Daniel Tschinder)
  • chore(package): update flow-bin to version 0.34.0 (#204) (Greenkeeper)

Don't miss a new babylon release

NewReleases is sending notifications on new releases.