Skip to content

Commit

Permalink
Make doc links to relative file paths (redwoodjs#4866)
Browse files Browse the repository at this point in the history
* fix typo in foreward

* fix links

* rename foreward to foreword continued

* fix intro link for now
  • Loading branch information
jtoar authored Mar 22, 2022
1 parent 9b7f55a commit 3f60c2f
Show file tree
Hide file tree
Showing 47 changed files with 190 additions and 189 deletions.
4 changes: 2 additions & 2 deletions docs/docs/app-configuration-redwood-toml.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The options and their structure are based on Redwood's notion of sides and targe

The idea is that, in the future, changes here will have cascading, "app-level" effects. Using generators as an example, based on your side and target, the generators will behave differently, but appropriately different.

> For the difference between a side and a target, see [Redwood File Structure](/docs/tutorial/chapter1/file-structure).
> For the difference between a side and a target, see [Redwood File Structure](tutorial/chapter1/file-structure.md).
You can think of `redwood.toml` as a convenience layer over Redwood's webpack configuration files. That is, for certain settings, instead of having to deal with webpack directly, we give you quick access via `redwood.toml`. Some of these settings are for development, some are for production, and some are for both. You can actually see this reflected in which webpack file each configuration option is referenced in—[webpack.development.js](https://github.com/redwoodjs/redwood/blob/main/packages/core/config/webpack.development.js), [webpack.production.js](https://github.com/redwoodjs/redwood/blob/main/packages/core/config/webpack.production.js), and [webpack.common.js](https://github.com/redwoodjs/redwood/blob/main/packages/core/config/webpack.common.js).

Expand Down Expand Up @@ -119,7 +119,7 @@ Where `API_KEY` is defined in .env or .env.defaults:
API_KEY=...
```

`includeEnvironmentVariables` is the set of environment variables to whitelist for the web side. You can also prefix environment variables with `REDWOOD_ENV_` (see [Environment Variables](https://redwoodjs.com/docs/environment-variables#web)).
`includeEnvironmentVariables` is the set of environment variables to whitelist for the web side. You can also prefix environment variables with `REDWOOD_ENV_` (see [Environment Variables](environment-variables.md#web)).

## [api]

Expand Down
22 changes: 12 additions & 10 deletions docs/docs/authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ Read the post-install instructions carefully as they contain instructions for ad
>
> yarn rw generate dbAuth
Note that if you change the fields named `hashedPassword` and `salt`, and you have some verbose logging in your app, you'll want to scrub those fields from appearing in your logs. See the [Redaction](/docs/logger#redaction) docs for info.
Note that if you change the fields named `hashedPassword` and `salt`, and you have some verbose logging in your app, you'll want to scrub those fields from appearing in your logs. See the [Redaction](logger.md#redaction) docs for info.

### Scaffolding Login/Signup/Forgot Password Pages

Expand Down Expand Up @@ -204,7 +204,7 @@ cookie: {

#### CORS config

If you're using dbAuth and your api and web sides are deployed to different domains then you'll need to configure CORS for both GraphQL in general and dbAuth. You'll also need to enable a couple of options to be sure and send/accept credentials in XHR requests. For more info, see the complete [CORS doc](/docs/cors#cors-and-authentication).
If you're using dbAuth and your api and web sides are deployed to different domains then you'll need to configure CORS for both GraphQL in general and dbAuth. You'll also need to enable a couple of options to be sure and send/accept credentials in XHR requests. For more info, see the complete [CORS doc](cors.md#cors-and-authentication).

#### Error Messages

Expand Down Expand Up @@ -261,7 +261,8 @@ yarn add @redwoodjs/auth netlify-identity-widget

#### Setup

You will need to enable Identity on your Netlify site. See [Netlify Identity Setup](https://redwoodjs.com/docs/tutorial/chapter4/authentication#netlify-identity-setup).
You will need to enable Identity on your Netlify site.
<!-- See [Netlify Identity Setup](tutorial/chapter4/authentication.md#netlify-identity-setup). -->

```js
// web/src/App.js
Expand Down Expand Up @@ -293,7 +294,7 @@ export default App

#### Netlify Identity Auth Provider Specific Setup

See the Netlify Identity information within this doc's [Auth Provider Specific Integration](https://redwoodjs.com/docs/authentication.html#auth-provider-specific-integration) section.
See the Netlify Identity information within this doc's [Auth Provider Specific Integration](#auth-provider-specific-integration) section.

+++

Expand All @@ -318,7 +319,8 @@ yarn add @redwoodjs/auth gotrue-js

#### Setup

You will need to enable Identity on your Netlify site. See [Netlify Identity Setup](https://redwoodjs.com/docs/tutorial/chapter4/authentication#netlify-identity-setup).
You will need to enable Identity on your Netlify site.
<!-- See [Netlify Identity Setup](tutorial/chapter4/authentication.md#netlify-identity-setup). -->

Add the GoTrue-JS package to the web side:

Expand Down Expand Up @@ -393,7 +395,7 @@ You can increase security by using refresh token rotation which issues a new ref

Rotating the refresh token reduces the risk of a compromised refresh token. For more information, see: [https://auth0.com/docs/tokens/refresh-tokens/refresh-token-rotation](https://auth0.com/docs/tokens/refresh-tokens/refresh-token-rotation).

> **Including Environment Variables in Serverless Deployment:** in addition to adding the following env vars to your deployment hosting provider, you _must_ take an additional step to include them in your deployment build process. Using the names exactly as given below, follow the instructions in [this document](https://redwoodjs.com/docs/environment-variables) to "Whitelist them in your `redwood.toml`".
> **Including Environment Variables in Serverless Deployment:** in addition to adding the following env vars to your deployment hosting provider, you _must_ take an additional step to include them in your deployment build process. Using the names exactly as given below, follow the instructions in [this document](environment-variables.md) to include them in your `redwood.toml`.
```js
// web/src/App.js
Expand Down Expand Up @@ -478,7 +480,7 @@ const UserAuthTools = () => {

#### Auth0 Auth Provider Specific Setup

See the Auth0 information within this doc's [Auth Provider Specific Integration](https://redwoodjs.com/docs/authentication.html#auth-provider-specific-integration) section.
See the Auth0 information within this doc's [Auth Provider Specific Integration](#auth-provider-specific-integration) section.

+++

Expand Down Expand Up @@ -544,7 +546,7 @@ Otherwise, feel free to configure your instances however you wish with regards t

> **Including Environment Variables in Serverless Deploys**
>
> In addition to adding these env vars to your local `.env` file or deployment hosting provider, you _must_ take an additional step to include them in your deployment build process. Using the names exactly as given above, follow the instructions in [this document](https://redwoodjs.com/docs/environment-variables). You should expose the `CLERK_FRONTEND_API_URL` only to the `web` workspace and expose `CLERK_API_KEY` **only** to the `api` workspace.
> In addition to adding these env vars to your local `.env` file or deployment hosting provider, you _must_ take an additional step to include them in your deployment build process. Using the names exactly as given above, follow the instructions in [this document](environment-variables.md). You should expose the `CLERK_FRONTEND_API_URL` only to the `web` workspace and expose `CLERK_API_KEY` **only** to the `api` workspace.
#### Login and Logout Options

Expand Down Expand Up @@ -680,7 +682,7 @@ yarn add @redwoodjs/auth magic-sdk

To get your application keys, go to [dashboard.magic.link](https://dashboard.magic.link/) then navigate to the API keys add them to your `.env`.

> **Including Environment Variables in Serverless Deployment:** in addition to adding the following env vars to your deployment hosting provider, you _must_ take an additional step to include them in your deployment build process. Using the names exactly as given below, follow the instructions in [this document](https://redwoodjs.com/docs/environment-variables) to "Whitelist them in your `redwood.toml`".
> **Including Environment Variables in Serverless Deployment:** in addition to adding the following env vars to your deployment hosting provider, you _must_ take an additional step to include them in your deployment build process. Using the names exactly as given below, follow the instructions in [this document](environment-variables.md) to "Whitelist them in your `redwood.toml`".
```js
// web/src/App.js|tsx
Expand Down Expand Up @@ -728,7 +730,7 @@ export default Routes

#### Magic.Link Auth Provider Specific Integration

See the Magic.Link information within this doc's [Auth Provider Specific Integration](https://redwoodjs.com/docs/authentication.html#auth-provider-specific-integration) section.
See the Magic.Link information within this doc's [Auth Provider Specific Integration](#auth-provider-specific-integration) section.
+++

### Firebase
Expand Down
8 changes: 4 additions & 4 deletions docs/docs/builds.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
> There's more to document here. In the meantime, you can check our [community forum](https://community.redwoodjs.com/search?q=yarn%20rw%20build) for answers.
>
> Want to contribute? Redwood welcomes contributions and loves helping people become contributors.
> You can edit this doc [here](https://github.com/redwoodjs/redwoodjs.com/blob/main/docs/builds.md).
> You can edit this doc [here](https://github.com/redwoodjs/redwoodjs.com/blob/main/docs/builds.md).
> If you have any questions, just ask for help! We're active on the [forums](https://community.redwoodjs.com/c/contributing/9) and on [discord](https://discord.com/channels/679514959968993311/747258086569541703).

Expand All @@ -24,10 +24,10 @@ yarn zip-it-and-ship-it dist/functions/ zipballs/
```

Each lambda function in `./api/dist/functions` is parsed by zip-it-and-ship-it resulting in a zip file per lambda function that contains all the dependencies required for that lambda function.

>Note: The `@netlify/zip-it-and-ship-it` package needs to be installed as a dev dependency in `api/`. Use the command `yarn workspace api add -D @netlify/zip-it-and-ship-it`.
>- You can learn more about the package [here](https://www.npmjs.com/package/@netlify/zip-it-and-ship-it).
>- For more information on AWS Serverless Deploy see these [docs](https://redwoodjs.com/docs/deploy#aws-serverless-deploy).
>- You can learn more about the package [here](https://www.npmjs.com/package/@netlify/zip-it-and-ship-it).
>- For more information on AWS Serverless Deploy see these [docs](deploy.md#serverless-deploy).
## Web

Expand Down
4 changes: 2 additions & 2 deletions docs/docs/cells.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ yarn rw generate cell equipment --list

We'll go over each of these files in detail. But know that the file appended with just `.js` (in the example above, `UserCell.js`) contains all your Cell's logic.

Off the bat, this file exports five constants: `QUERY`, `Loading` , `Empty` , `Failure` and `Success`. The root query in `QUERY` is the same as `<name>` so that, if you're generating a cell based on a model in your `schema.prisma`, you can get something out of the database right away. But there's a good chance you won't generate your Cell this way, so if you need to, make sure to change the root query. See the [Cells](/docs/tutorial/chapter2/cells#our-first-cell) section of the Tutorial for a great example of this.
Off the bat, this file exports five constants: `QUERY`, `Loading` , `Empty` , `Failure` and `Success`. The root query in `QUERY` is the same as `<name>` so that, if you're generating a cell based on a model in your `schema.prisma`, you can get something out of the database right away. But there's a good chance you won't generate your Cell this way, so if you need to, make sure to change the root query. See the [Cells](tutorial/chapter2/cells.md#our-first-cell) section of the Tutorial for a great example of this.

## Usage

Expand Down Expand Up @@ -326,7 +326,7 @@ When would you want to do this? If you just want a file to end in "Cell" for som
If we didn't do all that built-time stuff for you, how might you go about implementing a Cell yourself?
Consider the [example from the Tutorial](/docs/tutorial/chapter2/cells#our-first-cell) where we're fetching posts:
Consider the [example from the Tutorial](tutorial/chapter2/cells.md#our-first-cell) where we're fetching posts:
```javascript
export const QUERY = gql`
Expand Down
Loading

0 comments on commit 3f60c2f

Please sign in to comment.