Skip to content

Commit b76a12f

Browse files
committed
update links to remove /latest/ and add full v11 domain for older links
1 parent 294b1db commit b76a12f

File tree

104 files changed

+650
-336
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

104 files changed

+650
-336
lines changed

markdown-pages/blogposts/2020-08-10-bucklescript-is-rebranding.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,15 @@ There's no dedicated name for the syntax anymore. It's simply called the ReScrip
6464

6565
**Will there be a migration script to gradually convert our code to the new syntax?**
6666

67-
Yes. See our [migration page](/docs/manual/v10.0.0/migrate-from-bucklescript-reason). You can mix and match old and new code for a smoother transition.
67+
Yes. See our [migration page](https://v11.rescript-lang.org/docs/manual/v10.0.0/migrate-from-bucklescript-reason). You can mix and match old and new code for a smoother transition.
6868

6969
**Will BuckleScript (now ReScript) break my existing code?**
7070

7171
No. The new syntax & tools sit alongside the existing code. We **won't** remove OCaml and Reason support from ReScript for a long time.
7272

7373
**What's the editor tooling story?**
7474

75-
Much more streamlined now! See our [Editor Plugins](/docs/manual/latest/editor-plugins) page.
75+
Much more streamlined now! See our [Editor Plugins](/docs/manual/editor-plugins) page.
7676

7777
Reason-language-server will continue working as-is for existing usage. We as first party don't work on ocaml's language server.
7878

markdown-pages/blogposts/2020-12-07-release-8-4.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ dependent's command line flags for building binary artifacts. Such strategy bene
5555

5656
To make `bsb -make-world` more practical for e.g. multi-package setups (`lerna`, `yarn workspaces`, etc.), we introduced a new concept called `pinned-dependencies`. A pinned dependency allows you to automatically rebuild packages that are pinned by a toplevel package, like your final webapp.
5757

58-
Please refer to our [pinned dependencies](/docs/manual/latest/build-pinned-dependencies) docs for more details.
58+
Please refer to our [pinned dependencies](/docs/manual/build-pinned-dependencies) docs for more details.
5959

6060
### More robust handling of removal of staled output
6161

markdown-pages/blogposts/2021-02-09-release-9-0.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Our compiler comes with a set of stdlib modules (such as `Belt`, `Pervasives`, e
3434

3535
In previous versions, users couldn't ship their compiled JS code without defining a `package.json` dependency on `bs-platform`. Whenever a ReScript developer wanted to publish a package just for pure JS consumption / lean container deployment, they were required to use a bundler to bundle up their library / stdlib code, which made things way more complex and harder to understand.
3636

37-
To fix this problem, we introduced an `external-stdlib` configuration that allows specifying a pre-compiled stdlib npm package (`@rescript/std`). More details on how to use that feature can be found in our [External Stdlib](/docs/manual/latest/build-external-stdlib) documentation.
37+
To fix this problem, we introduced an `external-stdlib` configuration that allows specifying a pre-compiled stdlib npm package (`@rescript/std`). More details on how to use that feature can be found in our [External Stdlib](/docs/manual/build-external-stdlib) documentation.
3838

3939
### Less Bundle Bloat when Adding ReScript
4040

@@ -109,7 +109,7 @@ function is_space(param){
109109

110110
### `when` -> `if`
111111

112-
Starting from 9.0, [`when` clauses](/docs/manual/latest/pattern-matching-destructuring#when-clause) within a `switch` statement will automatically convert to the `if` keyword instead.
112+
Starting from 9.0, [`when` clauses](/docs/manual/pattern-matching-destructuring#when-clause) within a `switch` statement will automatically convert to the `if` keyword instead.
113113

114114
<CodeTab labels={["New (9.0)", "Old (8.4)"]}>
115115

markdown-pages/blogposts/2023-02-02-release-10-1.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ let logUserDetails = async (userId: string) => {
5151
}
5252
```
5353

54-
To learn more about our async / await feature, check out the relevant [manual section](/docs/manual/latest/async-await).
54+
To learn more about our async / await feature, check out the relevant [manual section](/docs/manual/async-await).
5555

5656
## New `promise` builtin type and `Js.Promise2` module
5757

markdown-pages/blogposts/2023-04-17-improving-interop.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ We can now utilize pattern matching fully without needing to do any conversion.
225225
This has a few implications:
226226

227227
- Dealing with external data, that is often nullable and seldom guaranteed to map cleanly to `option` without needing conversion, becomes much easier and zero cost.
228-
- Special handling like [@return(nullable)](https://rescript-lang.org/syntax-lookup#return-decorator) becomes redundant. This is good also because the current functionality does not work in all cases. The new functionality will work anywhere.
228+
- Special handling like [@return(nullable)](https://rescript-lang.org/syntax-lookup/return-decorator) becomes redundant. This is good also because the current functionality does not work in all cases. The new functionality will work anywhere.
229229

230230
### Decoding and encoding JSON idiomatically
231231

markdown-pages/blogposts/2023-05-17-enhanced-ergonomics-for-record-types.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ description: |
99

1010
> This is the second post covering new capabilities that'll ship in ReScript v11. You can check out the first post on [better interop with customizable variants here](https://rescript-lang.org/blog/improving-interop).
1111
12-
[Records](https://rescript-lang.org/docs/manual/latest/record) are a fundamental part of ReScript, offering a clear and concise definition of complex data structures, immutability by default, great error messages, and support for exhaustive pattern matching.
12+
[Records](https://rescript-lang.org/docs/manual/record) are a fundamental part of ReScript, offering a clear and concise definition of complex data structures, immutability by default, great error messages, and support for exhaustive pattern matching.
1313

1414
Even though records are generally preferable for defining structured data, there are still a few ergonomic annoyances, such as...
1515

1616
1. Existing record types can't be extended, which makes them hard to compose
1717
2. Functions may only accept record arguments of the exact record type (no explicit sub-typing)
1818

19-
To mitigate the limitations above, one would need to retreat to [structural objects](https://rescript-lang.org/docs/manual/latest/object#sidebar) to allow more flexible object field sharing and sub-typing, at the cost of more complex type errors and no pattern matching capabilities.
19+
To mitigate the limitations above, one would need to retreat to [structural objects](https://rescript-lang.org/docs/manual/object#sidebar) to allow more flexible object field sharing and sub-typing, at the cost of more complex type errors and no pattern matching capabilities.
2020

2121
We think that records are a much more powerful data structure though, so we want to encourage more record type usage for these scenarios. This is why ReScript v11 will come with two new big enhancements for record types: **Record Type Spread** and **Record Type Coercion**.
2222

@@ -141,7 +141,7 @@ let name = nameFromB(a :> b)
141141

142142
Notice how `a` now has more fields than `b`, but we can still coerce `a` to `b` because `b` has a subset of the fields of `a`.
143143

144-
In combination with [optional record fields](/docs/manual/latest/record#optional-record-fields), one may coerce a mandatory field of an `option` type to an optional field:
144+
In combination with [optional record fields](/docs/manual/record#optional-record-fields), one may coerce a mandatory field of an `option` type to an optional field:
145145

146146
```rescript
147147
type a = {

markdown-pages/blogposts/2024-01-11-release-11-0-0.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Use your favorite package manager to install the new compiler release, e.g.:
1616
npm install rescript@11
1717
```
1818

19-
To upgrade your project or to find out if there are any breaking changes that affect you, please follow the [migration guide](/docs/manual/latest/migrate-to-v11).
19+
To upgrade your project or to find out if there are any breaking changes that affect you, please follow the [migration guide](/docs/manual/migrate-to-v11).
2020

2121
The complete list of changes can be found [here](https://github.com/rescript-lang/rescript/blob/v11.0.0/CHANGELOG.md). Let's have a look at the most notable improvements.
2222

@@ -52,15 +52,15 @@ This release is also introducing uncurried mode, which is a new default mode tha
5252

5353
[ReScript Core](https://github.com/rescript-lang/rescript-core) is ReScript's new standard library. It replaces the complete `Js` module as well as some of the more frequently used modules from `Belt` and is recommended to use with uncurried mode.
5454

55-
The latest docs on [rescript-lang.org](/) already use it for the examples. Have a look at the new [RescriptCore API docs](/docs/manual/latest/api/core).
55+
The latest docs on [rescript-lang.org](/) already use it for the examples. Have a look at the new [RescriptCore API docs](/docs/manual/api/core).
5656

5757
## More Features
5858

5959
Furthermore, there are a lot of smaller improvements of which we want to state only a few here.
6060

6161
### More types eligible for type coercion
6262

63-
The `:>` (type coercion) operator now supports a few more datatypes, check out its [Syntax Lookup](/syntax-lookup#type-coercion) page.
63+
The `:>` (type coercion) operator now supports a few more datatypes, check out its [Syntax Lookup](/syntax-lookup/type-coercion) page.
6464

6565
### Build System
6666

@@ -90,7 +90,7 @@ It's now possible to have a module opened by default that is just part of the cu
9090

9191
Previously, the ReScript binary was able to initialize new projects itself. But it was required to have a global npm install to use it. This functionality has been removed.
9292

93-
Going forward, `create-rescript-app` is the new recommended way to setup a new project. It can even be used to quickly add ReScript to an existing project. Have a look at the updated [installation instructions](/docs/manual/latest/installation) for how to use it.
93+
Going forward, `create-rescript-app` is the new recommended way to setup a new project. It can even be used to quickly add ReScript to an existing project. Have a look at the updated [installation instructions](/docs/manual/installation) for how to use it.
9494

9595
### ReScript-React v0.12
9696

markdown-pages/blogposts/2024-02-01-release-11-1-0.mdx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@ let make = (~name) => {
4242
}
4343
```
4444

45-
Read more in the [new documentation on the generic JSX transform](/docs/manual/latest/jsx#generic-jsx-transform-jsx-beyond-react-experimental).
45+
Read more in the [new documentation on the generic JSX transform](/docs/manual/jsx#generic-jsx-transform-jsx-beyond-react-experimental).
4646

4747
## Tagged template literals
4848

4949
This release comes with support for [tagged templates](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#tagged_templates).
5050

51-
A tag function in JavaScript is a function that expects an array of strings and variadic parameters as input. Now it's possibe to bind to such functions with the new [`@taggedTemplate`](/syntax-lookup#taggedTemplate-decorator) decorator:
51+
A tag function in JavaScript is a function that expects an array of strings and variadic parameters as input. Now it's possibe to bind to such functions with the new [`@taggedTemplate`](/syntax-lookup/taggedTemplate-decorator) decorator:
5252

5353
<CodeTab labels={["ReScript", "JS Output"]}>
5454

@@ -78,7 +78,7 @@ Of course you can also create your own tag function in ReScript now as well, it
7878
let myTagFunction : (array<string>, array<'param>) => 'output
7979
```
8080

81-
Refer to the docs to find a [detailed example](/docs/manual/latest/tagged-templates).
81+
Refer to the docs to find a [detailed example](/docs/manual/tagged-templates).
8282

8383
## Import attributes
8484

@@ -130,7 +130,7 @@ var p = 2n ** 2n;
130130

131131
</CodeTab>
132132

133-
See [big integer docs](https://rescript-lang.org/docs/manual/latest/primitive-types#big-integers-experimental) for more.
133+
See [big integer docs](https://rescript-lang.org/docs/manual/primitive-types#big-integers-experimental) for more.
134134

135135
## Array spread syntax
136136

@@ -204,7 +204,7 @@ var result2 = JSON.stringify(obj, undefined, 2);
204204
205205
## %todo and warn-error
206206
207-
Inspired by languages like [Elm](https://package.elm-lang.org/packages/elm/core/latest/Debug#todo) or [Gleam](https://tour.gleam.run/advanced-features/todo/), we introduced a new extension point: [`%todo`](/syntax-lookup#todo).
207+
Inspired by languages like [Elm](https://package.elm-lang.org/packages/elm/core/latest/Debug#todo) or [Gleam](https://tour.gleam.run/advanced-features/todo/), we introduced a new extension point: [`%todo`](/syntax-lookup/todo).
208208
209209
It is used to tell the compiler that some code still needs to be implemented and it will crash when executed.
210210
@@ -242,7 +242,7 @@ We also made the compiler's `-warn-error` flag accessible by the build system, s
242242
rescript -warn-error +110
243243
```
244244
245-
See ["Compile with stricter errors in CI"](/docs/manual/latest/build-overview#compile-with-stricter-errors-in-ci).
245+
See ["Compile with stricter errors in CI"](/docs/manual/build-overview#compile-with-stricter-errors-in-ci).
246246
247247
## Other changes
248248

markdown-pages/blogposts/2025-03-05-what-can-i-do-with-rescript.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ description: |
77
Can I use Vite, or Next.js? Is it only for React? Can I use Node or Deno?
88
---
99

10-
You've taken a look and ReScript and you want to try it out, but how do you get started? There's the [installation](/docs/manual/latest/installation) page in the docs,
10+
You've taken a look and ReScript and you want to try it out, but how do you get started? There's the [installation](/docs/manual/installation) page in the docs,
1111
which is great if you want to set up a new React app using [create-rescript-app](https://github.com/rescript-lang/create-rescript-app). There's instructions on how to add it to an existing project or set it up manually.
1212
But that doesn't really answer the question "Can I use this with X?".
1313

@@ -25,7 +25,7 @@ Console.log("Hello")
2525
Just run `node index.res.js` and you'll see "Hello" logged to the console. You can import compiled ReScript into any project that could import JavaScript.
2626
If you can use `.js` or `.mjs` files, you can use ReScript. This does mean that languages with different file formats like Vue or Svelte require you to import the compiled JavaScript instead of writing it directly in the `.vue` or `.svelte` files.
2727

28-
Real world projects are more than JavaScript files that you write; they use libraries and frameworks. This is where [bindings](/docs/manual/latest/external) come into play.
28+
Real world projects are more than JavaScript files that you write; they use libraries and frameworks. This is where [bindings](/docs/manual/external) come into play.
2929
A binding is a way to tell ReScript the types and imports from external JavaScript. You can think of bindings in the same way that you need to create a `*.d.ts` file to add types to a JavaScript library that doesn't use TypeScript.
3030

3131
ReScript has great integration with [React](/docs/react/latest/introduction) and those bindings are kept up to date by the core team, but that doesn't mean you don't have other options!
@@ -80,8 +80,8 @@ const result = format(new Date(2014, 1, 11), "MM/dd/yyyy");
8080
```
8181

8282
That's all we need to know to write bindings to use this function in ReScript.
83-
The first thing we need to figure out is how to handle the type for what `date-fns` considers to be a `date`, which is `Date | string | number`. In ReScript things can't just be of different types like they can in JavaScript or TypeScript. There are a couple options here; you can make a function for each type such as `formatString` and `formatDate`, or you can create a [variant type](/docs/manual/latest/variant) to map to the possible input types.
84-
Creating a function for each type is simpler, and it's most likely how you will use the library in your project. You probably have a standard type for Dates already. We'll also need a type for `FormatDateOptions` in case we want to pass options. We'll use [labeled argmuments](/docs/manual/latest/function#labeled-arguments) for our binding.
83+
The first thing we need to figure out is how to handle the type for what `date-fns` considers to be a `date`, which is `Date | string | number`. In ReScript things can't just be of different types like they can in JavaScript or TypeScript. There are a couple options here; you can make a function for each type such as `formatString` and `formatDate`, or you can create a [variant type](/docs/manual/variant) to map to the possible input types.
84+
Creating a function for each type is simpler, and it's most likely how you will use the library in your project. You probably have a standard type for Dates already. We'll also need a type for `FormatDateOptions` in case we want to pass options. We'll use [labeled argmuments](/docs/manual/function#labeled-arguments) for our binding.
8585

8686
```res
8787
// DateFns.res - you might want to put this in a folder called "bindings" or "external"

markdown-pages/blogposts/archived/2017-10-02-bucklescript-release-1-4-2.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ users to re-read the documentation ([old
2424
docs](http://bucklescript.github.io/bucklescript/Manual.html#_build_system_support)).
2525

2626
2. [FFI add a new
27-
feature](/docs/manual/latest/bind-to-js-function#fixed-arguments)
27+
feature](/docs/manual/bind-to-js-function#fixed-arguments)
2828
3. [FFI can handle `bs.obj` and `bs.string`
2929
combination](https://github.com/bucklescript/bucklescript/issues/1072)

0 commit comments

Comments
 (0)