1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
Commit graph

19 commits

Author SHA1 Message Date
Juan Olvera 7e12997af6 Test updater script on examples folder (#5993)
I wrote a [script](https://github.com/j0lv3r4/dependency-version-updater) to update dependencies recursively in `package.json` files, e.g.:

```
$ node index.js --path="./examples" --dependencies="react=^16.7.0,react-dom=^16.7.0"
```

This PR contains the result against the examples folder.
2019-01-05 12:19:27 +01:00
Oscar Busk 71d1d363ad Fix/update "examples/custom-server-typescript" (#5865)
* Update all dependencies and remove redundant ones from package.json. (60f9ee5)
* Fixes #5596 by adjusting nodemon scripts (d4b7d3a)
* Fixes `npm start` on windows by using `cross-env` (9555217)
* Move compiled server out from `.next`. Compiling other JS into `.next` seems incorrect. (79fce02, 
9ce7086)
* Partly fixes #5753 by making sure typescript compiles with `es2017` as target, at least ensuring code is runnable on node 8. Previously it was compiled with `esnext`. (9176e92)

--- 

I tried improving the structure by keeping source in `src/app` and `src/server` and then building to `dist/server` and `dist/app` but I didn't really get it to work and made most configs more complicated. Moved the built server out from `.next` anyway.
2018-12-12 11:04:39 +01:00
Matt Jewell 7076727d3e Fix location of production server file (#5731)
(At least with my set up, mac osx, node 10.13.0, yarn 1.12.1)

Couldn't get the server to start with `npm start`, this appears to fix that
2018-11-22 16:55:47 +01:00
Davide Curletti 819efed2c0 Fix incorrect path for ts server example (#5612)
The customer-server-typescript example has a bug where the `yarn start` command has the incorrect path to the server entry point file.
2018-11-07 14:33:33 +01:00
Duncan L 6d5389ef2d Examples: Update custom-server-typescript examples packages (#5411) 2018-10-09 12:48:05 +02:00
Emmanuel Letallieur 82bdd43285 Fix custom-server-typescript not typechecking (#3954)
Hi

In the current version of the example __custom-server-typescript__, types are never checked.
For instance, change the following line :
```
const dev = process.env.NODE_ENV !== 'production'
```
by :
```
const dev: number = process.env.NODE_ENV !== 'production'
```
then run `npm run dev`. The application launches perfectly, no error is thrown.

In dev environnement, it is preferable to check types all the time, to get immediate feedback. This PR activates type checking. Only when using nodemon, so no impact on production.


Now the above code will (rightfully) refuse to compile : 
```
TSError: ⨯ Unable to compile TypeScript
server/index.ts (6,7): Type 'boolean' is not assignable to type 'number'
```
2018-09-04 17:35:34 +02:00
Alexander Kachkaev 9319c158a5 Upgrade Babel to 7.0.0-rc.1 (major) (#4937)
Fixes #4691
Fixes #4614

This PR gives path to https://github.com/zeit/next-plugins/pull/242

I did not add or remove `^` near dependency versions in package.json files. However, I don't exclude that some changes can be made given that rc is more stable than beta.
2018-08-13 10:34:08 -07:00
Michael Herold 5b3578e58f #4751 - Explicitly mention install when cloning examples (#4758)
Preferably this installation wouldn't be necessary, but in lieu of a fix...

#4751
2018-07-11 23:56:15 +02:00
Vinicius Pacheco Furtado de6bf4e75f Fix typescript examples (#4704)
Update @zeit/next-typescript version on examples using it
2018-06-30 22:23:38 +02:00
Luke Barton cbfdcce32d Update typescript examples to use 1.0.1 of next-typescript (#4472)
* Update typescript examples to use 1.0.1 of next-typescript

* Add .babelrc modifications to upgraded typescript examples
2018-05-25 11:28:35 +02:00
Rob Brennan 0330962618 Improve custom server typescript example v2 (#4470) 2018-05-25 11:03:59 +02:00
Seth Etter 769d8e3a84 Update next-typescript version in custom-typescript-server example (#4130) 2018-04-09 18:41:41 +02:00
James Hegedus f2e56609cd Examples: stabalise README format and create-next-app usage (#4009)
* Examples: clarify language around Yarn create & npx

* add missing READMEs and create-next-app usage

* suggest people tag jthegedus in firebase related issues

* add yarn alt instructions

* cerebraljs example readme & fixes
2018-04-03 14:19:05 +02:00
Tim Neutkens 069f45d74e Upgrade @zeit/next-typescript in custom-server-typescript example (patch) fixes #4071 2018-03-29 21:06:53 +02:00
James Hegedus b1d8b839dd Examples: use npx and yarn create to run create-next-app on examples (#4002)
* remove global npm install of create-next-app

* add npx to create-next-app command in examples

* add bash to shell snippets

* add yarn create to next-app command in examples

* fix READMEs named with lowercase

* change READMEs to use UPPERCASE
2018-03-14 09:09:46 +01:00
Wagner Camarao 0eb5bab452 Fix a/b typo in custom-server-typescript routing (#4003) 2018-03-14 09:06:53 +01:00
Alexander Kachkaev 2e641e9e8c Use separate tsconfig for server in custom-server-typescript example (#3963) 2018-03-07 09:13:12 +01:00
Alexander Kachkaev 39be7183a5 Update custom-server-typescript example (#3936)
- Add "jsx": "preserve" to tsconfig.json
- Rename lib to production-server to remove incompatibility with other examples

Context: https://github.com/zeit/next.js/pull/3838#issuecomment-370189242 and below
2018-03-05 09:49:48 +01:00
Ibrahim Ansari 99fb191286 Add custom-server-typescript example (see #3694) (#3838)
* Add custom-server-typescript example (see #3694)

* Fix linting errors in custom-server-typescript

* Provide proper arguments to ts-node.

* Fix import and fix all linting errors.

* Use import in server as well.

* Update nodemon.json
2018-02-22 16:29:47 +01:00