Skip to content

Commit

Permalink
📚 docs: Update.
Browse files Browse the repository at this point in the history
  • Loading branch information
make-github-pseudonymous-again committed Sep 4, 2022
1 parent b9bce68 commit 022fe7c
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 20 deletions.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,15 @@
[@collection-abstraction/set](https://collection-abstraction.github.io/set)
==

Python's set data structure for JavaScript. Parent is
Python's set data structure for JavaScript.
See [docs](https://collection-abstraction.github.io/set/index.html).
Parent is
[js-data-structures](https://github.com/make-github-pseudonymous-again/js-data-structures).

> :warning: Depending on your environment, the code may require
> `regeneratorRuntime` to be defined, for instance by importing
> [regenerator-runtime/runtime](https://www.npmjs.com/package/regenerator-runtime).
```js
set('abc').issubset( 'abcd' ) ; // true
```
Expand Down
5 changes: 0 additions & 5 deletions doc/css/style.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
/*header > a[data-ice="testLink"] {*/
/*display: none;*/
/*}*/

h1,
h2,
.navigation,
Expand Down Expand Up @@ -50,7 +46,6 @@ footer
background-color: #ccc;
}


span[data-ice="signature"] > span {
/*font-weight: bold;*/
font-style: italic;
Expand Down
16 changes: 12 additions & 4 deletions doc/manual/installation.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,22 @@
# Installation

Can be managed using
[jspm](http://jspm.io)
or [npm](https://github.com/npm/npm).
[yarn](https://yarnpkg.com/en/docs),
[npm](https://docs.npmjs.com),
or [jspm](https://jspm.org/docs).

### jspm

### yarn
```terminal
jspm install npm:@collection-abstraction/set
yarn add @collection-abstraction/set
```

### npm
```terminal
npm install @collection-abstraction/set --save
```

### jspm
```terminal
jspm install npm:@collection-abstraction/set
```
18 changes: 11 additions & 7 deletions doc/manual/usage.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
# Usage
The code needs a ES2015+ polyfill to work, for example
[regenerator-runtime/runtime](https://babeljs.io/docs/usage/polyfill).

> :warning: Depending on your environment, the code may require
> `regeneratorRuntime` to be defined, for instance by importing
> [regenerator-runtime/runtime](https://www.npmjs.com/package/regenerator-runtime).
First, require the polyfill at the entry point of your application
```js
await import( 'regenerator-runtime/runtime.js' ) ;
await import('regenerator-runtime/runtime.js');
// or
import 'regenerator-runtime/runtime.js' ;
import 'regenerator-runtime/runtime.js';
```

Then
Then, import the library where needed
```js
const number = await import( '@collection-abstraction/set' ) ;
const {set} = await import('@collection-abstraction/set');
// or
import number from '@collection-abstraction/set' ;
import {set} from '@collection-abstraction/set';
```
6 changes: 3 additions & 3 deletions doc/scripts/header.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ const domReady = function (callback) {
}
};

domReady(function () {
domReady(() => {
const projectname = document.createElement('a');
projectname.classList.add('project-name');
projectname.text = 'collection-abstraction/set';
projectname.text = '@collection-abstraction/set';
projectname.href = './index.html';

const header = document.querySelector('header');
Expand All @@ -24,7 +24,7 @@ domReady(function () {
const input = document.querySelector('.search-input');

// Active search box when focus on searchBox.
input.addEventListener('focus', function () {
input.addEventListener('focus', () => {
searchBox.classList.add('active');
});
});

0 comments on commit 022fe7c

Please sign in to comment.