Thanks much for this utility! Silly question, since we are calling:
`const id = newId();` in `yamultiselect`
should it then be something like:
```
newIdGenerator = {
let nextId = 0;
return function newId() {
return `${msns}-${++nextId}`;
};
}
const newId = newIdGenerator();
```
Currently, once the code in the cell is executed, the variable`newId` will have a function. Each call to the function returns `msns` appended with an integer that will be incremented.
The function is used to create different IDs for each instance of `yamultiselect` in an HTML page.
In the code you proposed, `newIdGenerator()` returns a string; which is stored in `newId`. So, `newId` when we use `newId` all instances of `yamultiselect` will have the same ID.
I am unable to import this Yet Another Multi-select library.
I am working in a .md file and doing all the imports in
```js
// here in this component
```
when I tried import {yamultiselect} from '@saneef/yet-another-multi-select', I got error saying 404 not found.
Package manager using - NPM
I assume you are trying to use this input into a [Observable Framework](https://observablehq.com/framework/) project. Currently, you can't import things from Observable Notebooks to Observable Frameworks.