Skip to content

Commit

Permalink
refactor!: drop support for node.js versions <12.16.x
Browse files Browse the repository at this point in the history
Summary: See ["Which node.js version are you using with the fbt Babel transforms? #217"](#217)

Reviewed By: jrwats

Differential Revision: D27899462

fbshipit-source-id: c09604e96856c9c3a592baa69b1359ee1988a426
  • Loading branch information
kayhadrin authored and facebook-github-bot committed Apr 24, 2021
1 parent ca6948a commit 2e6bb19
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node: [ '10.19', '12.16' ]
node: [ '12.16', '16.0' ]
test: [
'flow:check',
'babel-plugin-fbt:test',
Expand All @@ -26,7 +26,7 @@ jobs:
- uses: actions/checkout@v2
- name: Setup node
uses: actions/setup-node@v2-beta
with:
with:
node-version: ${{ matrix.node }}
- run: yarn install
- run: yarn run ${{matrix.test}}
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ List of changes for each released npm package version.
Unreleased changes that have landed in master. Click to see more.
</summary>

- [chore]! Drop support for node.js `<12.16.x`
- [feat] Add a new `FbtTranslations.getRegisteredTranslations` function
- [feat] Add a new `FbtTranslations.mergeTranslations` function
</details>
Expand Down Expand Up @@ -138,6 +139,7 @@ List of changes for each released npm package version.
Unreleased changes that have landed in master. Click to see more.
</summary>

- [chore]! Drop support for node.js `<12.16.x`
- [feat]! Refactor the string extraction algorithm to properly generate meaningful text/description pairs for fbt callsites that contain JSX presentational elements.
We're also adding support for a new way to call fbt() using an array of inputs instead of string concatenation.
See [#35](https://github.com/facebook/fbt/issues/35)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,6 @@
"packages/gulp-strip-docblock-pragmas"
],
"engines": {
"node": ">= 10.4.0"
"node": ">= 12.16.0"
}
}
2 changes: 1 addition & 1 deletion packages/babel-plugin-fbt/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ const babelPluginFbt_buildDistJS = () =>
babel({
plugins: [
require('@babel/plugin-proposal-optional-catch-binding'),
require('@babel/plugin-proposal-class-properties'),
require('@babel/plugin-syntax-class-properties'),
[require('@babel/plugin-syntax-flow'), {enums: true}],
require('babel-plugin-transform-flow-enums'),
require('babel-preset-fbjs/plugins/dev-expression'),
Expand Down
7 changes: 5 additions & 2 deletions packages/babel-plugin-fbt/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,22 @@
"description": "The FBT Babel localization transform",
"//version": "Follow SemVer specs at https://semver.org/",
"version": "0.20.0",
"engines": {
"node": ">= 12.16.0"
},
"bin": {
"fbt-collect": "dist/bin/collectFbt.bin.js",
"fbt-manifest": "dist/bin/manifest.bin.js",
"fbt-translate": "dist/bin/translate.bin.js"
},
"devDependencies": {
"@babel/plugin-proposal-class-properties": "7.1.0",
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.8.3",
"@babel/plugin-proposal-optional-catch-binding": "^7.2.0",
"@babel/plugin-proposal-optional-chaining": "^7.12.7",
"@babel/plugin-syntax-class-properties": "^7.2.0",
"@babel/plugin-syntax-flow": "^7.2.0",
"babel-plugin-transform-flow-enums": "^0.0.1",
"babel-preset-fbjs": "^3.1.2",
"babel-plugin-transform-flow-enums": "^0.0.1",
"flow-enums-runtime": "^0.0.3",
"gulp": "^4.0.0",
"gulp-babel": "^8.0.0",
Expand Down

0 comments on commit 2e6bb19

Please sign in to comment.