LinkedSoftwareDependencies / Components.js

🧩 A semantic dependency injection framework
https://componentsjs.readthedocs.io/
Other
41 stars 6 forks source link

Allow retrieving multiple components #26

Open RubenVerborgh opened 3 years ago

RubenVerborgh commented 3 years ago

Currently, instantiateFromUrl allows specifying one componentUrl. It would be interesting to specify an array and get back a key/value object.

RubenVerborgh commented 3 years ago

Implementation suggestion: it basically comes down to instantiating a Record<string, any> object; if needed, a dummy class could do:

class DummyRecord {
  constructor (record: Record<string, any>) {
    return record;
  }
}