question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Publish toolkit components as wrapped React components

See original GitHub issue

Feature/component description

As members of the community have been testing out the fast-react-wrapper in order to use the toolkit components inside React-based webview extensions the process of getting correctly set up has proven to be a bit difficult.

In order to ease some of the pain points and boilerplate currently required to get set up, we would like to explore taking on the responsibility of wrapping the toolkit components and publishing them so devs simply need to import the React toolkit component they desire.

Extra Context / Details / Thoughts

Ideally, the components can be imported using the following syntax (with the notable part being the /react sub-directory inside the toolkit package):

import { VSCodeButton } from "@vscode/webview-ui-toolkit/react";

Since this package will be consumed inside React and I believe (???) there is a reasonable expectation of being able to use ES Module syntax I’m going to say we probably don’t need to provide a bundled Rollup version of the React components and can instead focus all our attention on using the TypeScript compiler to build a set of ESM-based components within a react sub-directory.

With that said, I’m open to listening to arguments/use cases advocating for having a bundled Rollup version of the React components.

More thoughts will be included in the comments as I think of them.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
mattrothenbergcommented, Nov 16, 2021

No problem! Starring this issue and will post updates as I make them. Stay tuned.

2reactions
hawkticehurstcommented, Nov 16, 2021

No problem! Starring this issue and will post updates as I make them. Stay tuned.

Woo, thank you!! 🎉

Also obviously feel free to reach out with any Qs you might have as you get oriented with the repo.

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found