Skip to content

Commit 175295b

Browse files
authored
make install instructions more explicit
1 parent fef9efc commit 175295b

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

README.md

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,23 @@ The goal is to make it easy to write Lambda's with transpiled JS/Typescipt featu
66

77
## Installation
88

9-
**We recommend installing locally** rather than globally: `yarn add -D netlify-lambda`. This will ensure your build scripts don't assume a global install which is better for your CI/CD (for example with Netlify's buildbot).
9+
**We recommend installing locally** rather than globally:
1010

11-
If you don't have a [`netlify.toml`](https://www.netlify.com/docs/netlify-toml-reference/) file, you'll need one ([example](https://github.com/netlify/create-react-app-lambda/blob/master/netlify.toml)). Define the `functions` field where the functions will be built to and served from.
11+
```bash
12+
yarn add -D netlify-lambda
13+
```
14+
15+
This will ensure your build scripts don't assume a global install which is better for your CI/CD (for example with Netlify's buildbot).
16+
17+
If you don't have a [`netlify.toml`](https://www.netlify.com/docs/netlify-toml-reference/) file, you'll need one ([example](https://github.com/netlify/create-react-app-lambda/blob/master/netlify.toml)). Define the `functions` field where the functions will be built to and served from, e.g.
18+
19+
```toml
20+
# example netlify.toml
21+
[build]
22+
command = "yarn build"
23+
functions = "lambda" # netlify-lambda reads this
24+
publish = "build"
25+
```
1226

1327
## Usage
1428

0 commit comments

Comments
 (0)