Skip to content

Commit

Permalink
Merge branch 'release-next' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
brophdawg11 committed Mar 1, 2023
2 parents b792f8b + 73fc576 commit 3d92d46
Show file tree
Hide file tree
Showing 65 changed files with 421 additions and 261 deletions.
5 changes: 0 additions & 5 deletions .changeset/few-parents-leave.md

This file was deleted.

36 changes: 0 additions & 36 deletions .changeset/flat-routes-route-fixes.md

This file was deleted.

8 changes: 0 additions & 8 deletions .changeset/heavy-jars-accept.md

This file was deleted.

22 changes: 0 additions & 22 deletions .changeset/hmr.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/new-bulldogs-allow.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/tidy-doors-judge.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/tidy-singers-battle.md

This file was deleted.

9 changes: 0 additions & 9 deletions .changeset/twelve-seahorses-arrive.md

This file was deleted.

6 changes: 0 additions & 6 deletions .changeset/wise-masks-sniff.md

This file was deleted.

5 changes: 5 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ jobs:
- name: 📥 Install deps
run: yarn --frozen-lockfile

- name: Disable Eslint GitHub Actions Annotations
run: |
echo "::remove-matcher owner=eslint-compact::"
echo "::remove-matcher owner=eslint-stylish::"
- name: 🔬 Lint
run: yarn lint

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/reusable-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.10.0
uses: styfle/cancel-workflow-action@0.11.0

- name: ⬇️ Checkout repo
uses: actions/checkout@v3
Expand Down Expand Up @@ -113,7 +113,7 @@ jobs:
runs-on: macos-latest
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.10.0
uses: styfle/cancel-workflow-action@0.11.0

- name: ⬇️ Checkout repo
uses: actions/checkout@v3
Expand Down
30 changes: 20 additions & 10 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,44 +33,54 @@ yarn test react --watch

## Releases

New releases should be created from release branches originating from `dev`. When you are ready to begin the release process:
New releases should be created from release branches originating from the `dev` branch. When you are ready to begin the release process:

- Make sure you've pulled all of the changes from GitHub for both `dev` and `main` branches.
- Check out the `dev` branch.
- Pull all of the changes from GitHub.
- Create a new release branch with the `release-` prefix (eg, `git checkout -b release-next`)
- Create a new release branch with the `release-` prefix (eg, `git checkout -b release-next`).
- **IMPORTANT:** The `release-` prefix is important, as this is what triggers our GitHub CI workflow that will ultimately publish the release.
- Branches named `release-experimental` will not trigger our release workflow, as experimental releases handled differently (outlined below).
- Merge `main` into the release branch.

Changesets will do most of the heavy lifting for our releases. When changes are made to the codebase, an accompanying changeset file should be included to document the change. Those files will dictate how Changesets will version our packages and what shows up in the changelogs.

### Starting a new pre-release

- Ensure you are on the new `release-*` branch.
- Enter Changesets pre-release mode using the `pre` tag: `yarn changeset pre enter pre`.
- Commit the change and push the the `release-*` branch to GitHub.
- Commit the change and push the `release-*` branch to GitHub.
- Wait for the release workflow to finish. The Changesets action in the workflow will open a PR that will increment all versions and generate the changelogs.
- Review the PR, make any adjustments necessary, and merge it into the `release-*` branch.
- Review the updated `CHANGELOG` files and make any adjustments necessary, then merge the PR into the `release-*` branch.
- `find packages -name 'CHANGELOG.md' -mindepth 2 -maxdepth 2 -exec code {} \;`
- Once the PR is merged, the release workflow will publish the updated packages to npm.

### Incrementing a pre-release
### Iterating a pre-release

You may need to make changes to a pre-release prior to publishing a final stable release. To do so:

- Make whatever changes you need.
- Create a new changeset: `yarn changeset`.
- **IMPORTANT:** This is required even if you ultimately don't want to include these changes in the logs. Remember, changelogs can be edited prior to publishing, but the Changeset version script needs to see new changesets in order to create a new version.
- Commit the changesets and push the the `release-*` branch to GitHub.
- Wait for the release workflow to finish and the Changesets action to open its PR.
- Wait for the release workflow to finish and the Changesets action to open its PR that will increment all versions.
- Review the PR, make any adjustments necessary, and merge it into the `release-*` branch.
- Once the PR is merged, the release workflow will publish the updated packages to npm.

### Publishing the stable release

- Exit Changesets pre-release mode: `yarn changeset pre exit`.
- Commit the deleted pre-release file along with any unpublished changesets, and push the the `release-*` branch to GitHub.
- Wait for the release workflow to finish. The Changesets action in the workflow will open a PR that will increment all versions and generate the changelogs.
- Review the PR. We should remove the changelogs for all pre-releases ahead of publishing the stable version. [TODO: We should automate this]
- Commit the deleted pre-release file along with any unpublished changesets, and push the `release-*` branch to GitHub.
- Wait for the release workflow to finish. The Changesets action in the workflow will open a PR that will increment all versions and generate the changelogs for the stable release.
- Review the updated `CHANGELOG` files and make any adjustments necessary.
- We should remove the changelogs for all pre-releases ahead of publishing the stable version.
- [TODO: We should automate this]
- Merge the PR into the `release-*` branch.
- Once the PR is merged, the release workflow will publish the updated packages to npm.
- Once the release is published:
- merge the `release-*` branch into `main` and push it up to GitHub
- merge the `release-*` branch into `dev` and push it up to GitHub
- Convert the `[email protected]` tag to a Release on Github with the name `v1.x.y`
- Copy the relevant changelog entries from all packages into the Release Notes and adjust accordingly, matching the format used by prior releases

### Experimental releases

Expand Down
3 changes: 3 additions & 0 deletions contributors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,7 @@
- jwnx
- kalch
- kamtugeza
- kandros
- kanermichael
- karimsan
- kauffmanes
Expand Down Expand Up @@ -457,6 +458,7 @@
- thomasheyenbrock
- thomasrettig
- tjefferson08
- tombiju
- tombyrer
- toyozaki
- turkerdev
Expand Down Expand Up @@ -486,6 +488,7 @@
- wKovacs64
- wladiston
- wtlin1228
- wxh06
- xHomu
- XiNiHa
- xstevenyung
Expand Down
4 changes: 2 additions & 2 deletions docs/file-conventions/route-files-v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ routes/
app_.projects.$id.roadmap.tsx
```

Some, or all of them can be folders holding their own modules inside.
Some, or all of them can be folders holding their own `route` module inside.

```
routes/
Expand Down Expand Up @@ -359,7 +359,7 @@ routes/
contact-us.tsx
```

Note that `app/index.tsx` is _not_ the "index route" for `app/`. It is Note's "index module" for the directory `routes/app/`. The index route for `app/` is `app._index/index.tsx`. The only thing that contributes to the route path is the directory name.
Note that when you turn a route module into a folder, the route module becomes `folder/route.tsx`, all other modules in the folder will not become routes. For example:

```
# these are the same route:
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/constraints.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export default function Posts() {
}
```

The loader is gone but the prisma dependency stayed! Had we logged something harmless like `console.log("hello!")` it would be fine. But we logged the `prisma` module so the browser's gonna have a hard time with that.
The loader is gone but the prisma dependency stayed! Had we logged something harmless like `console.log("hello!")` it would be fine. But we logged the `prisma` module so the browser's going to have a hard time with that.

To fix this, remove the side effect by simply moving the code _into the loader_.

Expand Down
6 changes: 3 additions & 3 deletions docs/guides/data-loading.md
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ Given the following URLs, the search params would be parsed as follows:

### Data Reloads

When multiple nested routes are rendering and the search params change, all of the routes will be reloaded (instead of just the new or changed routes). This is because search params are a cross-cutting concern and could effect any loader. If you would like to prevent some of your routes from reloading in this scenario, use [shouldReload][should-reload].
When multiple nested routes are rendering and the search params change, all of the routes will be reloaded (instead of just the new or changed routes). This is because search params are a cross-cutting concern and could effect any loader. If you would like to prevent some of your routes from reloading in this scenario, use [shouldRevalidate][should-revalidate].

### Search Params in Components

Expand Down Expand Up @@ -667,7 +667,7 @@ There are three cases where Remix will reload all of your routes:
- If the url search params change (any loader could use them)
- The user clicks a link to the exact same URL they are already at (this will also replace the current entry in the history stack)

All of these behaviors emulate the browser's default behavior. In these cases, Remix doesn't know enough about your code to optimize the data loading, but you can optimize it yourself with [unstable_shouldReload][should-reload].
All of these behaviors emulate the browser's default behavior. In these cases, Remix doesn't know enough about your code to optimize the data loading, but you can optimize it yourself with [shouldRevalidate][should-revalidate].

## Data Libraries

Expand Down Expand Up @@ -746,7 +746,7 @@ export default function RouteComp() {
[prisma]: https://prisma.io
[request]: https://developer.mozilla.org/en-US/docs/Web/API/Request
[search-params-getall]: https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams/getAll
[should-reload]: ../route/should-reload
[should-revalidate]: ../route/should-revalidate
[url-search-params]: https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams
[url]: https://developer.mozilla.org/en-US/docs/Web/API/URL
[use-submit]: ../hooks/use-submit
Expand Down
2 changes: 1 addition & 1 deletion docs/hooks/use-fetchers.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ This is awesome for the checkbox, but the sidebar will say 2/4 while the checkbo
+-----------------+----------------------------┘
```

Because Remix will automatically reload the routes, the sidebar will quickly update and be correct. But for a moment, it's gonna feel a little funny.
Because Remix will automatically reload the routes, the sidebar will quickly update and be correct. But for a moment, it's going to feel a little funny.

This is where `useFetchers` comes in. Up in the sidebar, we can access all the inflight fetcher states from the checkboxes - even though it's not the component that created them.

Expand Down
5 changes: 5 additions & 0 deletions docs/other-api/adapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ Each adapter has the same API. In the future we may have helpers specific to the

## Community Adapters

- [`@mcansh/remix-fastify`][remix-fastify] - For [Fastify][fastify].
- [`@mcansh/remix-raw-http`][remix-raw-http] - For a good ol barebones Node server.
- [`remix-google-cloud-functions`][remix-google-cloud-functions] - For [Google Cloud][google-cloud-functions] and [Firebase][firebase-functions] functions.

## Creating an Adapter
Expand Down Expand Up @@ -180,3 +182,6 @@ addEventListener("fetch", (event) => {
[remix-google-cloud-functions]: https://github.com/penx/remix-google-cloud-functions
[google-cloud-functions]: https://cloud.google.com/functions
[firebase-functions]: https://firebase.google.com/docs/functions
[remix-fastify]: https://github.com/mcansh/remix-fastify
[fastify]: https://www.fastify.io
[remix-raw-http]: https://github.com/mcansh/remix-node-http-server
6 changes: 3 additions & 3 deletions docs/tutorials/blog.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ A solid practice is to create a module that deals with a particular concern. In
touch app/models/post.server.ts
```

We're mostly gonna copy/paste stuff from our route:
We're mostly going to copy/paste stuff from our route:

```tsx filename=app/models/post.server.ts
type Post = {
Expand Down Expand Up @@ -534,7 +534,7 @@ export default function PostSlug() {
}
```

Holy smokes, you did it. You have a blog. Check it out! Next, we're gonna make it easier to create new blog posts 📝
Holy smokes, you did it. You have a blog. Check it out! Next, we're going to make it easier to create new blog posts 📝

## Nested Routing

Expand Down Expand Up @@ -700,7 +700,7 @@ Now click the link from the index route and watch the `<Outlet/>` automatically

## Actions

We're gonna get serious now. Let's build a form to create a new post in our new "new" route.
We're going to get serious now. Let's build a form to create a new post in our new "new" route.

💿 Add a form to the new route

Expand Down
Loading

0 comments on commit 3d92d46

Please sign in to comment.