Skip to content

Commit cbc9eea

Browse files
giocalitridotNetkow
authored andcommitted
feat(appflow): Added docs on using different Node versions in Appflow (ionic-team#1089)
1 parent d551e4b commit cbc9eea

6 files changed

Lines changed: 33 additions & 3 deletions

File tree

52.2 KB
Loading

‎src/assets/locales/en/messages.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,7 @@
205205
"menu-appflow-cookbook-intro": "Overview",
206206
"menu-appflow-cookbook-private_git": "Using Private GIT repositories",
207207
"menu-appflow-cookbook-private_npm_modules": "Using Private NPM modules",
208+
"menu-appflow-cookbook-switch_node_version": "Use different Node in builds",
208209

209210
"menu-appflow-devapp": "DevApp: Local Development",
210211

‎src/components/menu/templates/appflow.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ const items = {
4848
'menu-appflow-cookbook': {
4949
'menu-appflow-cookbook-intro': '/docs/appflow/cookbook/intro',
5050
'menu-appflow-cookbook-private_git': '/docs/appflow/cookbook/private_git',
51-
'menu-appflow-cookbook-private_npm_modules': '/docs/appflow/cookbook/private_npm_modules'
51+
'menu-appflow-cookbook-private_npm_modules': '/docs/appflow/cookbook/private_npm_modules',
52+
'menu-appflow-cookbook-switch_node_version': '/docs/appflow/cookbook/switch_node_version'
5253
},
5354
'menu-appflow-devapp': '/docs/appflow/devapp'
5455
};

‎src/pages/appflow/cookbook/intro.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,5 @@ Learn how to access private Git repos used in npm dependencies.
1414
### [Using Private NPM Modules](/docs/appflow/cookbook/private_npm)
1515
Learn how to access private NPM modules used in dependencies.
1616

17+
### [Switching Node Version](/docs/appflow/cookbook/switch_node_version)
18+
Learn how to use a different Node in builds.

‎src/pages/appflow/cookbook/private_npm_modules.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
previousText: 'Using private GIT repositories'
33
previousUrl: '/docs/appflow/cookbook/private_git'
4-
nextText: 'DevApp: Local Development'
5-
nextUrl: '/docs/appflow/devapp'
4+
nextText: 'Use different Node in builds'
5+
nextUrl: '/docs/appflow/cookbook/switch_node_version'
66
---
77

88
# Using private NPM modules
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
previousText: 'Using private NPM moduless'
3+
previousUrl: '/docs/appflow/cookbook/private_npm_modules'
4+
nextText: 'DevApp: Local Development'
5+
nextUrl: '/docs/appflow/devapp'
6+
---
7+
8+
# Use different Node in builds
9+
10+
It is possible to use a different Node version other than the default one (currently Node 10) in a build.
11+
12+
13+
To switch Node version simply add a variable called `OVERRIDE_NODE_VERSION` inside an environment and use
14+
such environment in a build.
15+
16+
![Use different Node](/docs/assets/img/appflow/cookbook/switch-node-version.png)
17+
18+
#### Notes
19+
20+
The environment variable `OVERRIDE_NODE_VERSION` can only be set
21+
to an integer representing the major version: `8`, `10` and `12` are currently allowed.
22+
23+
Even if `12.13.0` is a valid version, it is not a valid input; `13` is not currently available.
24+
25+
If `OVERRIDE_NODE_VERSION` is set to a version that is not a good
26+
input or that is not available, the Node version will be defaulted to `10`

0 commit comments

Comments
 (0)