Skip to content

Commit c09e330

Browse files
committed
More formatting changes
1 parent 66268c5 commit c09e330

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

15/umbraco-cms/customizing/development-flow/vite-package-setup.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -63,18 +63,16 @@ Before proceeding, ensure that you install the version of the Backoffice package
6363
npm install -D @umbraco-cms/backoffice
6464
```
6565

66-
{% hint style="info" %}
67-
To avoid installing additional dependencies such as TinyMCE or Monaco Editor,use the `--legacy-peer-deps` flag:
68-
{% endhint %}
66+
6. To avoid installing additional dependencies such as TinyMCE or Monaco Editor,use the `--legacy-peer-deps` flag:
6967

7068
```bash
7169
npm install --legacy-peer-deps -D @umbraco-cms/backoffice
7270
```
7371

7472
This disables IntelliSense for external references but keeps the install lean.
7573

76-
6. Open the `tsconfig.json` file.
77-
7. Add the array `types` inside `compilerOptions`, with the entry of `@umbraco-cms/backoffice/extension-types`:
74+
7. Open the `tsconfig.json` file.
75+
8. Add the array `types` inside `compilerOptions`, with the entry of `@umbraco-cms/backoffice/extension-types`:
7876

7977
```json
8078
{
@@ -87,7 +85,7 @@ This disables IntelliSense for external references but keeps the install lean.
8785
}
8886
```
8987

90-
8. Create a new `vite.config.ts` file in the **client** folder:
88+
9. Create a new `vite.config.ts` file in the **client** folder:
9189

9290
{% code title="vite.config.ts" lineNumbers="true" %}
9391
```ts
@@ -119,15 +117,17 @@ The source code that is compiled lives in the `src` folder of your package folde
119117

120118
The `build:lib:entry` parameter can accept an array which will allow you to export multiple files during the build. You can read more about [Vite's build options here](https://vitejs.dev/config/build-options.html#build-lib).
121119

122-
Build the `ts` file in the **client** folder so we can use it in our package:
120+
10. Build the `ts` file in the **client** folder:
123121

124122
```bash
125123
npm run build
126124
```
127125

128126
## Watch for changes and build
129127

130-
If you like to continuously work on the package and have each change built, you can add a `watch`script in your `package.json` with `vite build --watch`. The example below indicates where in the structure this change should be implemented:
128+
To continuously work on the package and have each change built, add a `watch`script in your `package.json` with `vite build --watch`.
129+
130+
The example below indicates where in the structure this change should be implemented:
131131

132132
{% code title="package.json" lineNumbers="true" %}
133133
```json
@@ -142,7 +142,7 @@ If you like to continuously work on the package and have each change built, you
142142
```
143143
{% endcode %}
144144

145-
Then in the terminal, you can run `npm run watch`.
145+
Run `npm run watch` in the terminal.
146146

147147
## Umbraco Package declaration
148148

@@ -188,9 +188,9 @@ Learn more about the abilities of the manifest file in the [Umbraco Package Mani
188188
189189
#### Testing your package
190190
191-
To be able to test your package, you will need to run your site.
191+
To test your package, run your site.
192192
193-
Before you do this, you need to make sure to run `npm run build` to compile your TypeScript files and copy them to the `App_Plugins/client` folder.
193+
Before doing this, make sure to run `npm run build` to compile your TypeScript files and copy them to the `App_Plugins/client` folder.
194194
195195
{% hint style="warning" %}
196196
If you try to include some of these resources via Visual Studio (VS), then make sure not to include TypeScript files. Otherwise, VS will try to include a few lines on your `.csproj` file to compile the TypeScript code that exists in your project folder. When you run your website, VS will try to compile these files and fail.
@@ -200,7 +200,7 @@ The final result looks like this:
200200
201201
<figure><img src="../../.gitbook/assets/Vite_Package_Setup_Dashboard (1).png" alt=""><figcaption><p>My dashboard</p></figcaption></figure>
202202
203-
Back in the `src/my-element.ts` file, you can update the `styles` property to make any styling changes. You can change the `background-color` of the `button` to white so it is more visible:
203+
In the `src/my-element.ts` file, update the `styles` property to make any styling changes. You can change the `background-color` of the `button` to white so it is more visible:
204204
205205
```css
206206
button {

0 commit comments

Comments
 (0)