Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move extension to webpack-based build to support Typescript sources #78

Merged
merged 3 commits into from
Jan 4, 2023

Conversation

dfederschmidt
Copy link
Contributor

@dfederschmidt dfederschmidt commented Dec 29, 2022

This PR moves the build / development process to support Typescript files.

For now, all JS will work as-is since all valid JavaScript is also valid TypeScript, enabling an incremental adoption of Typescript. But since we need to compile TS sources into JS at build time, webpack is introduced.

Currently, the main entrypoint to the extension is out/extension.js. With webpack added, the npm run watch task will use webpack to compile all sources inside out/ into the dist/ folder. Now, dist/extension.ts is the new entrypoint for the extension.

The PR changes the "Run Extension" debug task to automatically launch the npm run watch task to ensure that webpack is run continuously throughout the development.

It also adds a new debug task to run the extension in an isolated extension host with a temporary settings profile ("Run Extension Isolated"). Note that this requires workbench.experimental.settings profiles.enabled to be set to true in the developers user settings.

@JasonConger JasonConger merged commit d0f6d94 into splunk:master Jan 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants