stdweb icon indicating copy to clipboard operation
stdweb copied to clipboard

Custom Elements: CustomElementRegistry

Open prasannavl opened this issue 5 years ago • 0 comments

[WIP] Initial impl of CustomElementRegistry

I do have a few questions before completing this:

  1. How exactly do I represent a Constructor here? (https://github.com/koute/stdweb/pull/299/commits/51e683cf749127918bfaa44bfd9426af3125a53e#diff-55e0c9ca42d6126fc52bcae5a9a2bf95R38)
  2. Is it okay to unwrap, this? Initially I did a no_return, but then added the error type, and as such the Result<(), Err>. Does this fit the project conventions? (https://github.com/koute/stdweb/pull/299/commits/51e683cf749127918bfaa44bfd9426af3125a53e#diff-55e0c9ca42d6126fc52bcae5a9a2bf95R41)
  3. Again, constructor type. But also, can Option be returned. Does this fit the project conventions, or should this be a result with empty error/not found error? What's the best way to represent undefined here. (https://github.com/koute/stdweb/pull/299/commits/51e683cf749127918bfaa44bfd9426af3125a53e#diff-55e0c9ca42d6126fc52bcae5a9a2bf95R48)
  4. I followed this convention by looking at other implementations, but it is correct to unwrap this? (https://github.com/koute/stdweb/pull/299/commits/51e683cf749127918bfaa44bfd9426af3125a53e#diff-55e0c9ca42d6126fc52bcae5a9a2bf95R59)

prasannavl avatar Nov 07 '18 21:11 prasannavl