Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@babel/plugin-syntax-flow

Package Overview
Dependencies
Maintainers
4
Versions
95
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/plugin-syntax-flow - npm Package Compare versions

Comparing version
8.0.0-rc.2
to
8.0.0-rc.3
+1
-1
lib/index.js
import { declare } from '@babel/helper-plugin-utils';
var index = declare((api, options) => {
api.assertVersion("^7.0.0-0 || ^8.0.0 || 8.0.0-rc.2");
api.assertVersion("^7.0.0-0 || ^8.0.0 || 8.0.0-rc.3");
const {

@@ -6,0 +6,0 @@ all,

@@ -1,1 +0,1 @@

{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["import { declare } from \"@babel/helper-plugin-utils\";\n\nexport interface Options {\n all?: boolean;\n}\n\nexport default declare((api, options: Options) => {\n api.assertVersion(REQUIRED_VERSION(\"^7.0.0-0 || ^8.0.0\"));\n\n // When enabled and plugins includes flow, all files should be parsed as if\n // the @flow pragma was provided.\n // @ts-expect-error Babel 7\n const { all, enums } = options;\n\n if (typeof all !== \"boolean\" && all !== undefined) {\n throw new Error(\".all must be a boolean, or undefined\");\n }\n\n if (enums !== undefined) {\n throw new Error(\n \"The .enums option has been removed and it's now always enabled. Please remove it from your config.\",\n );\n }\n\n return {\n name: \"syntax-flow\",\n\n manipulateOptions(opts, parserOpts) {\n parserOpts.plugins.push([\"flow\", { all }]);\n },\n };\n});\n"],"names":["declare","api","options","assertVersion","all","enums","undefined","Error","name","manipulateOptions","opts","parserOpts","plugins","push"],"mappings":";;AAMA,YAAeA,OAAO,CAAC,CAACC,GAAG,EAAEC,OAAgB,KAAK;EAChDD,GAAG,CAACE,aAAa,CAAA,kCAAuC,CAAC,CAAA;EAKzD,MAAM;IAAEC,GAAG;AAAEC,IAAAA,KAAAA;AAAM,GAAC,GAAGH,OAAO,CAAA;EAE9B,IAAI,OAAOE,GAAG,KAAK,SAAS,IAAIA,GAAG,KAAKE,SAAS,EAAE;AACjD,IAAA,MAAM,IAAIC,KAAK,CAAC,sCAAsC,CAAC,CAAA;AACzD,GAAA;EAEA,IAAIF,KAAK,KAAKC,SAAS,EAAE;AACvB,IAAA,MAAM,IAAIC,KAAK,CACb,oGACF,CAAC,CAAA;AACH,GAAA;EAEA,OAAO;AACLC,IAAAA,IAAI,EAAE,aAAa;AAEnBC,IAAAA,iBAAiBA,CAACC,IAAI,EAAEC,UAAU,EAAE;AAClCA,MAAAA,UAAU,CAACC,OAAO,CAACC,IAAI,CAAC,CAAC,MAAM,EAAE;AAAET,QAAAA,GAAAA;AAAI,OAAC,CAAC,CAAC,CAAA;AAC5C,KAAA;GACD,CAAA;AACH,CAAC,CAAC;;;;"}
{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["import { declare } from \"@babel/helper-plugin-utils\";\n\nexport interface Options {\n all?: boolean;\n}\n\nexport default declare((api, options: Options) => {\n api.assertVersion(REQUIRED_VERSION(\"^7.0.0-0 || ^8.0.0\"));\n\n // When enabled and plugins includes flow, all files should be parsed as if\n // the @flow pragma was provided.\n // @ts-expect-error Babel 7\n const { all, enums } = options;\n\n if (typeof all !== \"boolean\" && all !== undefined) {\n throw new Error(\".all must be a boolean, or undefined\");\n }\n\n if (enums !== undefined) {\n throw new Error(\n \"The .enums option has been removed and it's now always enabled. Please remove it from your config.\",\n );\n }\n\n return {\n name: \"syntax-flow\",\n\n manipulateOptions(opts, parserOpts) {\n parserOpts.plugins.push([\"flow\", { all }]);\n },\n };\n});\n"],"names":["declare","api","options","assertVersion","all","enums","undefined","Error","name","manipulateOptions","opts","parserOpts","plugins","push"],"mappings":";;AAMA,YAAeA,OAAO,CAAC,CAACC,GAAG,EAAEC,OAAgB,KAAK;EAChDD,GAAG,CAACE,aAAa,CAAA,kCAAuC,CAAC;EAKzD,MAAM;IAAEC,GAAG;AAAEC,IAAAA;AAAM,GAAC,GAAGH,OAAO;EAE9B,IAAI,OAAOE,GAAG,KAAK,SAAS,IAAIA,GAAG,KAAKE,SAAS,EAAE;AACjD,IAAA,MAAM,IAAIC,KAAK,CAAC,sCAAsC,CAAC;AACzD,EAAA;EAEA,IAAIF,KAAK,KAAKC,SAAS,EAAE;AACvB,IAAA,MAAM,IAAIC,KAAK,CACb,oGACF,CAAC;AACH,EAAA;EAEA,OAAO;AACLC,IAAAA,IAAI,EAAE,aAAa;AAEnBC,IAAAA,iBAAiBA,CAACC,IAAI,EAAEC,UAAU,EAAE;AAClCA,MAAAA,UAAU,CAACC,OAAO,CAACC,IAAI,CAAC,CAAC,MAAM,EAAE;AAAET,QAAAA;AAAI,OAAC,CAAC,CAAC;AAC5C,IAAA;GACD;AACH,CAAC,CAAC;;;;"}
{
"name": "@babel/plugin-syntax-flow",
"version": "8.0.0-rc.2",
"version": "8.0.0-rc.3",
"description": "Allow parsing of the flow syntax",

@@ -20,9 +20,9 @@ "repository": {

"dependencies": {
"@babel/helper-plugin-utils": "^8.0.0-rc.2"
"@babel/helper-plugin-utils": "^8.0.0-rc.3"
},
"peerDependencies": {
"@babel/core": "^8.0.0-rc.2"
"@babel/core": "^8.0.0-rc.3"
},
"devDependencies": {
"@babel/core": "^8.0.0-rc.2"
"@babel/core": "^8.0.0-rc.3"
},

@@ -29,0 +29,0 @@ "engines": {