Skip to content

Commit d7bd8c0

Browse files
authored
Merge pull request #782 from live-codes/docs
edit docs
2 parents b5314e5 + a1f9011 commit d7bd8c0

6 files changed

Lines changed: 41 additions & 6 deletions

File tree

docs/docs/getting-started.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ LiveCodes [<abbr title="Software Development Kit">SDK</abbr>](./sdk/index.mdx) i
2727

2828
Install from npm.
2929

30-
```shell
31-
npm i livecodes
30+
```bash npm2yarn
31+
npm install livecodes
3232
```
3333

3434
then you can use it like that:

docs/docs/languages/vue.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ Using [Prettier](https://prettier.io/).
408408
Currently, Vue support has the following limitations:
409409

410410
- SSR is not supported.
411-
- The [`defineProps()`](https://vuejs.org/guide/components/props#props-declaration) macro cannot infer props from TypeScript types. Props have to be explicitly declared.
411+
- The [`defineProps()`](https://vuejs.org/guide/components/props#props-declaration) macro cannot infer props from TypeScript types not defined in the same file.
412412

413413
[PRs are welcome](https://github.com/live-codes/livecodes/issues/757).
414414

docs/docs/sdk/index.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ This is an example of an editable embedded playground using the SDK.
3131
This is a single npm package for the SDK which supports JavaScript/TypeScript, React, Vue and Svelte.
3232
Install the library from npm:
3333

34-
```sh
35-
npm i livecodes
34+
```bash npm2yarn
35+
npm install livecodes
3636
```
3737

3838
then it can be used like that:
@@ -116,6 +116,6 @@ A demo page that shows the usage of the SDK can be [found here](https://live-cod
116116

117117
Or edit the SDK playground in LiveCodes. How meta! :)
118118

119-
<LiveCodes import="id/nqdxpnj6uvg" view="result" height="80vh" showCode={false} />
119+
<LiveCodes import="id/8k6vbxitvb9" config={{ view: 'result' }} height="80vh" showCode={false} />
120120

121121
P.S. You may want to use the "Full Screen" button!

docs/docusaurus.config.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,12 @@ const config: Config = {
3535
const sidebarItems = await defaultSidebarItemsGenerator(args);
3636
return excludeSidebarItems(sidebarItems);
3737
},
38+
remarkPlugins: [
39+
[
40+
require('@docusaurus/remark-plugin-npm2yarn'),
41+
{ sync: true, converters: ['yarn', 'pnpm', 'bun'] },
42+
],
43+
],
3844
},
3945
blog: false,
4046
theme: {
@@ -220,6 +226,7 @@ const config: Config = {
220226
prism: {
221227
theme: lightCodeTheme,
222228
darkTheme: darkCodeTheme,
229+
additionalLanguages: ['bash'],
223230
},
224231
algolia: {
225232
appId: 'H9Z2PKYS80',

docs/package-lock.json

Lines changed: 27 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"@docusaurus/faster": "3.7.0",
2020
"@docusaurus/plugin-client-redirects": "3.7.0",
2121
"@docusaurus/preset-classic": "3.7.0",
22+
"@docusaurus/remark-plugin-npm2yarn": "3.7.0",
2223
"@mdx-js/react": "3.1.0",
2324
"clsx": "2.1.1",
2425
"prism-react-renderer": "2.4.1",

0 commit comments

Comments
 (0)