Skip to content

Commit 73dab42

Browse files
committed
options for constructor in one object
1 parent da87cd7 commit 73dab42

File tree

3 files changed

+6
-8
lines changed

3 files changed

+6
-8
lines changed

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,11 @@ const InlineCode = require('codex.editor.inline-code');
2929

3030
### Load from CDN
3131

32-
Get newest bundle path from [RawGit](https://rawgit.com) — open site and paste link to JS bundle in repository.
32+
You can load specific version of package from [jsDelivr CDN](https://www.jsdelivr.com/package/npm/codex.editor.inline-code).
3333

34-
`https://github.com/codex-editor/inline-code/blob/master/dist/bundle.js`
34+
`https://cdn.jsdelivr.net/npm/codex.editor.inline-code@1.0.1`
3535

36-
> Note: use `production` link with commit hash to avoid issues with caching.
37-
38-
Then require this script on page with CodeX Editor.
36+
Require this script on a page with CodeX Editor.
3937

4038
```html
4139
<script src="..."></script>

dist/bundle.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ require('./index.css').toString();
1010
*/
1111
class InlineCode {
1212
/**
13-
* @param {object} api - CodeX Editor API
13+
* @param {{api: object}} - CodeX Editor API
1414
*/
15-
constructor(api) {
15+
constructor({api}) {
1616
this.api = api;
1717

1818
/**

0 commit comments

Comments
 (0)