Skip to content

Commit

Permalink
Adds warning about js/jsx files within the pages dir (#3011)
Browse files Browse the repository at this point in the history
  • Loading branch information
benjaminhoffman authored and KyleAMathews committed Nov 28, 2017
1 parent 00d16f0 commit 0cedc0e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/docs/building-with-components.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ A basic directory structure of a project might look like this:

### Page components

Components under `src/pages` become pages automatically with paths based on their file name. For example `src/pages/index.jsx` is mapped to `yoursite.com` and `src/pages/about.jsx` becomes `yoursite.com/about/`.
Components under `src/pages` become pages automatically with paths based on their file name. For example `src/pages/index.jsx` is mapped to `yoursite.com` and `src/pages/about.jsx` becomes `yoursite.com/about/`. Every `.js` or `.jsx` file in the pages directory must resolve to either a string or react component, otherwise your build will fail.

Example:

Expand Down

0 comments on commit 0cedc0e

Please sign in to comment.