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

Pass custom config options to labextensions frontend #2790

Closed
rsinha25 opened this issue Aug 6, 2017 · 2 comments
Closed

Pass custom config options to labextensions frontend #2790

rsinha25 opened this issue Aug 6, 2017 · 2 comments
Labels
question status:resolved-locked Closed issues are locked after 30 days inactivity. Please open a new issue for related discussion. tag:Extensions
Milestone

Comments

@rsinha25
Copy link

rsinha25 commented Aug 6, 2017

Hi,

I used to do this in the earlier labextension using the steps mentioned in the tutorial:

# Jupyter Lab Extension config data.
def _jupyter_labextension_config():
  """Get a dictionary of configuration data to provide to the JupyterLab frontend.

  This is called at each launch of the `/lab` page, and makes data available 
  through the `getConfigOption` [function](http://jupyterlab.github.io/services/globals.html#getconfigoption).

  Example in ES6 JavaScript:
  import { utils } from '@jupyterlab/services';
  let myVar = utils.getConfigOption('my_fancy_module_variable');
  """
  return dict(my_fancy_module_variable=1)

However, this doesn't work in the latest version as there is no python package anymore. How can I now pass custom config options and use them in labextension frontend?

@rsinha25 rsinha25 changed the title Pass custom config extensions to labextensions frontend Pass custom config options to labextensions frontend Aug 6, 2017
@blink1073
Copy link
Member

We decided that front end and back end extensions should remain separate. An extension that wants to affect the backend must also provide a server extension. They can affect the front end using page_config, an example of which is here.

@blink1073
Copy link
Member

Closing as answered, please feel free to reopen if you disagree.

@lock lock bot added the status:resolved-locked Closed issues are locked after 30 days inactivity. Please open a new issue for related discussion. label Aug 9, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Aug 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
question status:resolved-locked Closed issues are locked after 30 days inactivity. Please open a new issue for related discussion. tag:Extensions
Projects
None yet
Development

No branches or pull requests

2 participants