Commit graph

4221 commits

Author SHA1 Message Date
hanneslund
6025c2eedd Update README.md (#8780)
api-routes -> with-aws-amplify-typescript
2019-09-18 10:37:18 +02:00
Joe Haddad
65358b7a33
Global CSS Support (#8710)
* Global CSS Support

* Fix webpack configuration

* oneOf rule isn't necessary yet

* Adjust CSS chunk naming

* Begin testing CSS behavior

* Add another test TODO

* Replace null-loader with ignore-loader

* Turn on chunks for new CSS feature

* Fix multi test suite

* Test CSS import order

* Test style HMR

* Test CSS compilation

* Test compilation and prefixing together

* Verify CSS styling works for Development and Production

* Add missing TODO

* Remove unnecessary test

* Adjust TODO message

* Hide page until React hydrates

* Revert "Hide page until React hydrates"

This reverts commit 898d4e0ee547b003d5790e2b11476740d645b907.

* Hide FOUC during development

* Test CSS imports

* Update tests TODO

* Add fixture for url() test

* Test `file-loader` support in CSS files

* Use a simple variant of cssnano

* Self-import

* Undo bundling

* Implement suggestion
2019-09-17 16:05:20 -04:00
Joe Haddad
20aa1e4d21
v9.0.6 2019-09-17 14:21:38 -04:00
Joe Haddad
85f84a040a
v9.0.6-canary.7 2019-09-17 13:24:34 -04:00
JJ Kasper
b210133907 Show dots for non-TTY (#8771) 2019-09-17 13:22:51 -04:00
JJ Kasper
ba07cc6237 Revert "Add hard retrying for Azure test runs (#8761)" (#8772)
This reverts commit 664cd3fa04.
2019-09-17 19:01:46 +02:00
JJ Kasper
664cd3fa04 Add hard retrying for Azure test runs (#8761)
* Test killing proceses before retrying on Azure

* catch error while killing process
2019-09-17 12:17:34 -04:00
Weston Thayer
dc28e5b706 Example update: with-sentry-simple (#8684)
* Update to capture server exceptions and more

- Adds test cases for several server and client-side exceptions
- Allows capturing more server-side exceptions by overriding _error.js and using Sentry.captureException() within
- Use @sentry/node on the server
- Rely on Next.js's React Error Boundary instead of creating our own in _app.js

* Update test notes

Found some differences while testing in production

* Remove accidental mount throw on test 8

* Add note about server-side source maps

* Linting fixes
2019-09-17 11:43:51 +02:00
Joe Haddad
aa98323ed0
v9.0.6-canary.6 2019-09-17 00:22:13 -04:00
JJ Kasper
129e32f8ad
Fix windows paths mismatching for type errors (#8766) 2019-09-16 21:30:09 -05:00
JJ Kasper
4e9e51035e Match public files priority in dev (#8641)
* Match public files priority in dev

* Remove un-needed old public file handling

* Run public file priority test for non-dev also

* Make sure to enable publicDirectory

* Add checking for conflicting pages in dev and during build

* Add error for public dir middleware conflict

* Add err.sh for _next conflict

* Move up public dir conflict checking

* Only run _next conflict check in dev when path contains it
2019-09-16 23:06:30 +02:00
Tim Neutkens
369eceb0e7 v9.0.6-canary.5 2019-09-16 20:35:55 +02:00
Tommy Ljungberg
960906553b fix(examples): use hooks in with-cookie-auth example (#8729) 2019-09-16 19:57:15 +02:00
JJ Kasper
583b4677ae Prevent URL from being updated while asPath is delayed (#8756)
* Prevent updating URL when delaying asPath

* Ignore TypeScript not liking __NEXT_DATA__

* Update another global to fix standard check
2019-09-16 12:15:18 -04:00
JJ Kasper
204028d6ab Update build feedback with dots indicating activity (#8382)
* Add progress for analyzing and auto-prerendering

* Add typing for tty-aware-progress and use stdout

* Add fancier spinners

* Update spinner and add handling for logs while spinning

* Remove un-needed types package

* Remove progress and combine analyzing/prerendering messages
2019-09-16 17:37:00 +02:00
JJ Kasper
44bbf9ad27 Catch error from failing to unobserve (#8578)
* Catch error from failing to unobserve

* Update link.tsx
2019-09-16 16:56:56 +02:00
Lukáš Huvar
7863b60ef6 Prettier fix (#8754) 2019-09-16 15:24:42 +02:00
Azim Atefi
a0341ea150 Convert Readme Custom Error Pages To Functional Component (#8513)
* Convert Readme Custom Error Pages To Functional Component

* Update packages/next/README.md

Co-Authored-By: Tim Neutkens <tim@timneutkens.nl>

* Run readme through prettier
2019-09-16 14:30:50 +02:00
Lukáš Huvar
3e81acee56 Improve prettier ignore (#8753) 2019-09-16 14:18:08 +02:00
JJ Kasper
fe7c7342c7 Add link to docs for prerender indicator and allow disabling (#8610)
* Add link to docs for prerender indicator and allow disabling

* Fix lint error from example

* Disable by default when electron is detected

* Add button to dismiss indicator for session

* Update disabling indicator in electron
2019-09-15 23:18:11 +02:00
JJ Kasper
ed5dc2107f Add autoExport to __NEXT_DATA__ (#8746)
* Add autoExport to __NEXT_DATA__

* Update render variable
2019-09-15 20:35:14 +02:00
Joe Haddad
00e0281d71
v9.0.6-canary.4 2019-09-14 17:42:59 -04:00
Joe Haddad
d031cf64df
Ensure requests are resolved as directories (#8742)
* Ensure requests are resolved as directories
`resolveRequest` will strip down to baseDir if there's no trailing slash as it assumes you passed a file.

* Disable telemetry for PR Stats
2019-09-14 17:41:05 -04:00
Joe Haddad
cbd427bf3c
Document the intended behavior of our externals (#8741)
This fully annotates our externals code to explain how it should be functioning. This will be useful as tests cases are made to ensure this is working correctly.
2019-09-14 16:58:45 -04:00
Maël Nison
9770d192f2 Prevents externalizing non-hoisted packages (#8739) 2019-09-14 16:12:25 -04:00
Tim Neutkens
8cc6071347
Update readme.md 2019-09-14 21:21:41 +02:00
JJ Kasper
b5d61579c8 Make sure to fail export when prerender fails with serverless bundle (#8738)
* Make sure to error on serverless prerender failure

* Add test case

* Update index.test.js
2019-09-13 19:02:15 -04:00
JJ Kasper
2ae8b345db
v9.0.6-canary.3 2019-09-13 14:49:59 -05:00
JJ Kasper
c8e1e141e1
Make sure renderOpts is available before checking (#8734)
* Make sure renderOpts is available before checking

* Apply suggestions from code review

Co-Authored-By: Joe Haddad <joe.haddad@zeit.co>

* Update check
2019-09-13 14:43:45 -05:00
JJ Kasper
5c83684b89
Update pull_request workflow 2019-09-13 12:03:36 -05:00
Joe Haddad
fb83462713
Externalize experimental package (#8731)
* Add missing dependency

* Ignore prepass for Next.js internal

* Revert "Add missing dependency"

This reverts commit 9ef0030b56255577364ff7cab46f513216a290ae.
2019-09-13 12:38:25 -04:00
Joe Haddad
25451ce47a
v9.0.6-canary.2 2019-09-13 10:53:16 -04:00
Romain
98f368f545 Add missing Link import to routing doc (#8728) 2019-09-13 14:43:14 +02:00
Joe Haddad
d046dc6072
Disable telemetry for tests (#8725) 2019-09-12 22:51:56 -04:00
JJ Kasper
80ab8dd991
Update actions config 2019-09-12 13:20:30 -05:00
JJ Kasper
85f96c8fb8
Migrate GitHub Action config and remove un-used secret (#8719) 2019-09-12 13:13:15 -05:00
Henrik Wenz
1045cd4c5a Refactor api-routes-apollo-server-and-client example (#8673)
* Remove connectToDevTools in favour of better default

Disabled devtools in production

* Refactor api-routes-apollo-server-and-client example
2019-09-12 10:44:53 -05:00
Lukáš Huvar
9731e7e99c [Docs] Prefetch disabled for 2g or SaveData header (#8717) 2019-09-12 13:11:34 +02:00
JJ Kasper
2139f66ac3 Add test for duplicate scripts and add extra de-duping (#8709) 2019-09-11 17:20:47 -04:00
Joe Haddad
eb8c11bbda
Organize webpack configuration imports (#8711)
This PR simply organizes the webpack config imports.
2019-09-11 16:41:29 -04:00
Joe Haddad
55369051f5
Warn build on duplicate pages (#8646)
* Fail build on duplicate pages
This will fail the `next build` command when a duplicate page is found.
In development, we'll emit a warning instead of crashing the dev server.

* Add test for warning in development

* Only issue a warning

* Fix production test

* Fix development test

* Remove useless arg

* Warn in development, too
2019-09-11 14:26:10 -04:00
Joe Haddad
594851111b
Nit: sort experimental keys (#8707) 2019-09-11 14:10:51 -04:00
JJ Kasper
5a0dcbc95b Update pages-loader to return one value (#8629)
* Update pages-loader to return one value

* de-dupe page mod update also
2019-09-11 13:21:10 -04:00
Joe Haddad
fcadad9960
TypeScript report on active pages only (#8703)
* TypeScript report on active pages only
The TypeScript integration needs to report on active pages only.
When inactive pages are reported, they block the compilation and prevent the user from fixing the error (because the file isn't watched).

We cannot add the file to the webpack watcher because the compilation has already been sealed.

* Remove TODO message

* Test that inactive pages are not type checked
2019-09-11 13:06:48 -04:00
JJ Kasper
e5aa9614e1 Lock CircleCi image for now (#8706)
* use legacy image for now

* Use image hash

* Update config
2019-09-11 12:56:32 -04:00
Joe Haddad
53f4f82e4c
Catch all requests in custom server (#8704)
Some users aren't aware they need to edit their custom server to support various HTTP Methods (e.g. POST for API Routes).

Instead, we should just handle all HTTP Methods out-of-the-box.

---

Closes #8237
2019-09-11 10:23:41 -04:00
Michael Lustig
a809368e59 Fix login popup not working (#8700) 2019-09-10 22:16:20 -04:00
Jakub Karabuła-Stysiak
5496e0f8b3 Add electron typescript example (#8682)
* Add initial Electron-Typescript-Next example

* Move and add types

* Update readme

* Update renderer

* remove config
2019-09-10 14:22:00 -05:00
JJ Kasper
a5ebe41a9a Delay updating asPath for auto exported pages (#8681)
* Delay updating asPath for auto exported pages

* Add additional test ensuring asPath is updated
2019-09-10 13:30:25 -04:00
Joe Haddad
79090718da
Test non-flag and re-runs of telemetry cmds (#8697) 2019-09-10 13:21:10 -04:00