Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: create official Netlify Remix template #83

Merged
merged 43 commits into from
Feb 24, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
9acd178
chore: updated eslint configuration for template
nickytonline Feb 10, 2023
4c12998
chore: updated gitignore
nickytonline Feb 10, 2023
daaf46d
chore: updated template
nickytonline Feb 10, 2023
dc06b86
Merge remote-tracking branch 'origin/main' into nickytonline/update-t…
nickytonline Feb 10, 2023
a29a2b2
chore: fixed node package change for new template references
nickytonline Feb 10, 2023
0ff5692
chore: first batch of updates to template
nickytonline Feb 14, 2023
b0109a0
chore: added an example of cache headers
nickytonline Feb 15, 2023
48e08e6
chore: some markup cleanup
nickytonline Feb 15, 2023
d560631
chore: removed package lock
nickytonline Feb 15, 2023
7bda544
chore: put back globals.d.ts
nickytonline Feb 15, 2023
73c22a4
Revert "chore: first batch of updates to template"
nickytonline Feb 16, 2023
2ffae3a
chore: removed headers from edge version of netlify.toml
nickytonline Feb 16, 2023
69e8617
chore: put back node eslint config
nickytonline Feb 16, 2023
1a8d04d
chore: updated tsconfig.json
nickytonline Feb 16, 2023
4928004
chore: folders can now be excluded from template generation
nickytonline Feb 18, 2023
480051b
chore: added force to removing the excluded folders
nickytonline Feb 18, 2023
2c603f3
chore: netlify configurations and READMEs get set by remix.init now
nickytonline Feb 18, 2023
330b1a5
chore: added README for the project, not the templates
nickytonline Feb 18, 2023
52fd58b
chore: added a CoC and contributing guidelines
nickytonline Feb 18, 2023
db09d8e
chore: shortened cache control time example headers for Remix running…
nickytonline Feb 18, 2023
3b4f673
Merge branch 'main' into nickytonline/update-template
nickytonline Feb 18, 2023
e0ca52a
chore: removed references to Netlify Graph
nickytonline Feb 20, 2023
5b5eda5
chore: removed unnecessary disabling of lint rule
nickytonline Feb 20, 2023
547422f
Update remix.init/index.js
nickytonline Feb 20, 2023
4f2270b
Update README.md
nickytonline Feb 20, 2023
f1526f3
Update remix.init/README.md
nickytonline Feb 20, 2023
5b133cf
Update README.md
nickytonline Feb 20, 2023
09af36a
Update remix.init/README-edge.md
nickytonline Feb 20, 2023
e9576e9
chore: README updates
nickytonline Feb 20, 2023
fd3139b
chore: edge template now uses renderReadableStream
nickytonline Feb 21, 2023
d86cc3b
chore: small cleanup
nickytonline Feb 21, 2023
6603201
Update remix.init/README-edge.md
nickytonline Feb 22, 2023
ba24c63
chore: remix.init ignores toml files so changed filename
nickytonline Feb 22, 2023
41a1243
chore: fixed file copy issues when project language is JS
nickytonline Feb 22, 2023
cbe3f15
chore: excluded the .gitfolder from template generation
nickytonline Feb 22, 2023
2de5663
chore: removed debugger statement
nickytonline Feb 22, 2023
0d8a01c
chore: fixed issue with isbot require
nickytonline Feb 22, 2023
e7122a1
chore: added a step to mention running npm install in case remix.init…
nickytonline Feb 22, 2023
3c57b0c
chore: added /_assets/* to exclude_patterns and documented excluding …
nickytonline Feb 23, 2023
973d282
chore: added missing await
nickytonline Feb 24, 2023
faa0b8b
chore: added final step to install additional packages for edge setup
nickytonline Feb 24, 2023
887128c
Update remix.init/README-edge.md
nickytonline Feb 24, 2023
be32ac6
chore: added an explainer on how to use the template
nickytonline Feb 24, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions remix.init/README-edge.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,25 @@ Open up [http://localhost:3000](http://localhost:3000), and you should be ready

Note: When running the Netlify CLI, file changes will rebuild assets, but you will not see the changes to the page you are on unless you do a browser refresh of the page. Due to how the Netlify CLI builds the Remix App Server, it does not support hot module reloading.

### Excluding routes
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a new section I added @stephmarie17. Could the wording be improved?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a suggestion below!


If you want to exclude routes for non-Remix code, e.g. for custom Netlify Functions or Netlify Edge Functions, add an additional entry in the array, e.g.:
nickytonline marked this conversation as resolved.
Show resolved Hide resolved

```diff
export const config = {
cache: "manual",
path: "/*",
// Let the CDN handle requests for static assets, i.e. /_assets/*
//
// Add other exclusions here, e.g. "/api/*" for custom Netlify functions or
// custom Netlify Edge Functions
- excluded_patterns: ["/_assets/*"],
+ excluded_patterns: ["/_assets/*", "/api/*"],
};
```

These changes can be made in [server.js](./server.js).

## Deployment

There are two ways to deploy your app to Netlify, you can either link your app to your git repo and have it auto deploy changes to Netlify, or you can deploy your app manually. If you've followed the setup instructions already, all you need to do is run this:
Expand Down
5 changes: 5 additions & 0 deletions remix.init/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,9 @@ export default createRequestHandler({
export const config = {
cache: "manual",
path: "/*",
// Let the CDN handle requests for static assets, i.e. /_assets/*
//
// Add other exclusions here, e.g. "/api/*" for custom Netlify functions or
// custom Netlify Edge Functions
excluded_patterns: ["/_assets/*"],
};