Skip to content

Commit

Permalink
fix(docs): Fixing formatting of code groups and previews (#6601)
Browse files Browse the repository at this point in the history
* Fix docs multi tabs and previews (Fixes #6597)
* Add permalink for .env file (Fixes #6574)
  • Loading branch information
mmaietta committed Feb 1, 2022
1 parent 70c3517 commit b01d522
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 12 deletions.
9 changes: 5 additions & 4 deletions docs/auto-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,13 @@ All these targets are default, custom configuration is not required. (Though it
2. [Configure publish](configuration/publish.md).

3. Use `autoUpdater` from `electron-updater` instead of `electron`:

```js tab="JavaScript"

JavaScript
```js
const { autoUpdater } = require("electron-updater")
```

```js tab="ES2015"
ES2015
```js
import { autoUpdater } from "electron-updater"
```

Expand Down
11 changes: 7 additions & 4 deletions docs/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@ Platforms and archs can be configured or using [CLI args](https://github.com/ele
For example, if you don't want to pass `--ia32` and `--x64` flags each time, but instead build by default NSIS target for all archs for Windows:

!!! example "Configuration"
```json tab="package.json"

package.json
```json
"build": {
"win": {
"target": [
Expand All @@ -91,8 +93,9 @@ For example, if you don't want to pass `--ia32` and `--x64` flags each time, but
}
}
```

``` yaml tab="electron-builder.yml"

electron-builder.yml
``` yaml
win:
target:
- target: nsis
Expand All @@ -108,4 +111,4 @@ build -wl

### TargetConfiguration
* **<code id="TargetConfiguration-target">target</code>** String - The target name. e.g. `snap`.
* <code id="TargetConfiguration-arch">arch</code> "x64" | "ia32" | "armv7l" | "arm64"&gt; | "x64" | "ia32" | "armv7l" | "arm64" - The arch or list of archs.
* <code id="TargetConfiguration-arch">arch</code> "x64" | "ia32" | "armv7l" | "arm64" | "x64" | "ia32" | "armv7l" | "arm64" - The arch or list of archs.
2 changes: 1 addition & 1 deletion docs/configuration/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Most of the options accept `null` — for example, to explicitly set that DMG ic

## Environment Variables from File

Env file `electron-builder.env` in the current dir ([example](https://github.com/motdotla/dotenv-expand/blob/master/test/.env)). Supported only for CLI usage.
Env file `electron-builder.env` in the current dir ([example](https://github.com/motdotla/dotenv-expand/blob/1cc80d02e1f8aa749253a04a2061c0fecb9bdb69/tests/.env)). Supported only for CLI usage.

## How to Read Docs

Expand Down
7 changes: 4 additions & 3 deletions docs/configuration/nsis.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,15 +131,16 @@ For portable app, following environment variables are available:

Yes, you need to switch to assisted installer (not default one-click).

```json tab="package.json"
package.json
```json
"build": {
"nsis": {
"oneClick": false
}
}
```

```yaml tab="electron-builder.yml"
electron-builder.yml
```yaml
nsis:
oneClick: false
```

0 comments on commit b01d522

Please sign in to comment.