You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+8-12Lines changed: 8 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -131,20 +131,16 @@ Though it is not a hard requirement, we'd deeply appreciate if you could recomme
131
131
132
132
#### Adding support to a new language
133
133
134
-
1. Create a dictionary file in `src/i18n/dictionaries`. The name should follow our locale convention.
134
+
1. Create a dictionary file in `src/i18n/dictionaries/{locale}/ui.ts`. The name should follow our locale convention.
135
135
136
-
- language (ISO 639-1 - set 1): https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes
136
+
- language (ISO 639-1 - set 1): https://en.wikipedia.org/wiki/List_of_ISO_639_language_codes
137
+
- country code(optional) (ISO 3166-1 alpha-2): https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2
138
+
- E.g.: Canadian French would be: `fr-ca`
137
139
138
-
- country code (ISO 3166-1 alpha-2): https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2
139
-
140
-
- E.g.: Canadian French would be: `fr-ca`
141
-
142
-
2. Add it to the barrel file: `src/i18n/dictionaries/index.ts`. So it will be identified by the routing system.
143
-
144
-
3. Add the important UI translations.
145
-
146
-
> [!TIP]
147
-
> To save time, you can use chatGPT to translate the `default.ts` dictionary to the language and adjust based on context.
140
+
2. Add the `import` and language information to the objects in the barrel file: `./src/i18n/dictionaries/index.ts`. So it will be identified by the routing system, and an entry its added to the language dropdown.
141
+
3. Add the language to the `array` in `./scripts/collections/index.mjs` so internal files are created.
142
+
4. Add the important UI translations to `./src/i18n/dictionaries/{locale}/ui.ts`
143
+
5. Add at least the index page `./src/routes/{locale}/index.mdx`, so others and yourself could see things in action.
Copy file name to clipboardExpand all lines: WRITING.md
+21-19Lines changed: 21 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,11 +27,13 @@ But beyond just your written content, there are several other things to consider
27
27
#### Tables
28
28
29
29
Though not used all that often, tables are an important tool for several reasons:
30
+
30
31
- They break up text.
31
32
- They offer clear information to the reader.
32
33
- They are easy to look through and understand.
33
34
34
35
Solid uses Markdown for tables, so here's how to make one.
36
+
35
37
1. Start with a vertical line, also called a pipe: `|`.
36
38
2. Insert your first heading and end with another pipe.
37
39
3. Write the next heading and end it with a pipe. Repeat until you have your column headings.
@@ -87,10 +89,10 @@ Start with three back ticks, ```, write your code, then close the block with thr
87
89
88
90
Here's an example in raw Markdown:
89
91
90
-
```
92
+
````
91
93
```bash
92
94
npm install
93
-
``````
95
+
````
94
96
95
97
Code examples are vital to providing users with quick tips on how to use Solid.
96
98
Knowing when to use inline code versus code blocks can further the understanding of the readers and users alike.
@@ -130,7 +132,7 @@ For each additional hash, you go down one heading level.
130
132
Here's an example of a Heading 1 (H1) and a Heading 2 (H2) in raw Markdown.
131
133
132
134
```
133
-
# SolidJS documentation
135
+
# Solid documentation
134
136
135
137
## Introduction
136
138
```
@@ -174,9 +176,9 @@ We would prefer you to keep page linking in mind while you're working on your co
174
176
The following two points are what you should pay attention to:
175
177
176
178
1. Interlink when you refer to a topic that has its own page.
177
-
This makes it possible for the user to easily seek additional information.
179
+
This makes it possible for the user to easily seek additional information.
178
180
2. Be descriptive with the linked text.
179
-
Do not use "click here" or any variation therein, as this is not a best practice for accessibility.
181
+
Do not use "click here" or any variation therein, as this is not a best practice for accessibility.
180
182
181
183
Links are written in Markdown.
182
184
Here's an example of what that looks like:
@@ -229,7 +231,7 @@ When writing steps in a how-to section, please start sentences with a verb.
229
231
### Accessible
230
232
231
233
Accessibility has taken a front seat in most aspects of technology in recent years, including documentation.
232
-
Solid should be accessible to anyone who wishes to use it, meaning that your writing has to meet some basic standards.
234
+
Solid should be accessible to anyone who wishes to use it, meaning that your writing has to meet some basic standards.
233
235
234
236
Some accessibility comes down to visual style, as we discussed.
235
237
However, it goes hand-in-hand with inclusiveness (which we'll get to next), so there is some overlap between the two.
@@ -302,16 +304,16 @@ This is a list of Solid-specific words and what they mean. In the second column,
302
304
303
305
These are technical; use them with the default assumption that the reader doesn't know what they mean.
304
306
305
-
| Terms to use | Terms not to use | Definition |
306
-
| --- | --- | --- |
307
-
| Computation, reactive computation | *Not to be confused with*: computed | A scope that automatically reruns when its dependencies change (it doesn't necessarily _have_ dependencies). |
308
-
| Core primitive | API function | A primitive provided by the Solid core library; this typically provides reactive behaviors but not necessarily ( `createContext` does not). |
309
-
| Custom primitive | hook | A primitive created outside of the Solid core library; i.e., a function that provides a composable piece of functionality. |
310
-
| Ownership, owns | | A one-to-many relationship between computations; if a computation "owns" one or more other computations, all its owned computations are cleaned up when it is cleaned up. |
311
-
| Primitive | Hook | A function that serves as a building block of reactivity or behavior. usually begins with `create` or `use`. |
312
-
| Reactive value | Signal (don't use to describe a general reactive value) | A value that can be tracked (includes signals, memos, properties of `props` and stores). |
313
-
| Reactivity | | A system for writing expressions or behaviors that depend on certain values and execute when those values change. |
314
-
| Root | | A computation that has no owner. created by `createRoot`. |
315
-
| Scope | *Not to be confused with:* root, effect (specific kinds of scopes) | A body of a function (a chunk of code). |
316
-
| Solid | SolidJS (unless outside the community/internal writings) | A JavaScript framework made up of a library (providing primitives and UI utilities) and a compiler (allowing you to write in JSX). Its differentiating feature is its reactivity system. |
317
-
| Tracking scope | Tracking context, reactive context, reactive scope, reactive root | A scope that, when run, Solid automatically tracks all read signals |
| Computation, reactive computation |_Not to be confused with_: computed | A scope that automatically reruns when its dependencies change (it doesn't necessarily _have_ dependencies).|
310
+
| Core primitive | API function | A primitive provided by the Solid core library; this typically provides reactive behaviors but not necessarily ( `createContext` does not).|
311
+
| Custom primitive | hook | A primitive created outside of the Solid core library; i.e., a function that provides a composable piece of functionality.|
312
+
| Ownership, owns || A one-to-many relationship between computations; if a computation "owns" one or more other computations, all its owned computations are cleaned up when it is cleaned up.|
313
+
| Primitive | Hook | A function that serves as a building block of reactivity or behavior. usually begins with `create` or `use`.|
314
+
| Reactive value | Signal (don't use to describe a general reactive value) | A value that can be tracked (includes signals, memos, properties of `props` and stores).|
315
+
| Reactivity || A system for writing expressions or behaviors that depend on certain values and execute when those values change.|
316
+
| Root || A computation that has no owner. created by `createRoot`.|
317
+
| Scope |_Not to be confused with:_ root, effect (specific kinds of scopes) | A body of a function (a chunk of code).|
318
+
| Solid | SolidJS (unless outside the community/internal writings)| A JavaScript framework made up of a library (providing primitives and UI utilities) and a compiler (allowing you to write in JSX). Its differentiating feature is its reactivity system. |
319
+
| Tracking scope | Tracking context, reactive context, reactive scope, reactive root | A scope that, when run, Solid automatically tracks all read signals|
0 commit comments