You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2019/11/23 02:04:35 UTC

[GitHub] [incubator-superset] suddjian opened a new pull request #8638: Package linking

suddjian opened a new pull request #8638: Package linking
URL: https://github.com/apache/incubator-superset/pull/8638
 
 
   ### CATEGORY
   
   Choose one
   
   - [ ] Bug Fix
   - [ ] Enhancement (new features, refinement)
   - [ ] Refactor
   - [ ] Add tests
   - [x] Build / Development Environment
   - [ ] Documentation
   
   ### SUMMARY
   <!--- Describe the change below, including rationale and design decisions -->
   
   This adds a tool to aid local plugin development/debugging by linking all of the packages in the `superset-ui-plugins` repo. A new npm script, `plugin-devmode-on`, `npm link`s all the superset-ui-plugins. A new webpack config detects any npm linked superset-ui-plugins, and automatically changes imports for those plugins to import from `/src`. This makes a [whole series of steps](https://github.com/apache-superset/superset-ui/blob/master/docs/debugging.md) unnecessary. You can set the location to use for the repo with the env variable `SUPERSET_UI_PLUGINS_PATH`.
   
   Another npm script `plugin-devmode-off` undoes the changes of `plugin-devmode-on` by running `npm ci`.
   
   *This is not entirely working, just yet.* The `BoxPlotChartPlugin` in `@superset-ui/preset-chart-xy` plugin is imported by reaching into the `/esm/legacy' directory. This breaks, because webpack rewrites it to look for `/esm`, a build directory, in `/src`. We propose to solve this by either modernizing the plugin (no idea how easy/difficult that is), or splitting it into a legacy version and a non-legacy version, so that we don't need to reach inside a build folder to import the chart. Input would be appreciated from anyone with more insight into the history of that plugin.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org