mirror of
https://github.com/jupyter/notebook.git
synced 2025-01-12 11:45:38 +08:00
Pass config into nbconvert exporters
This commit is contained in:
parent
eb680ddaa6
commit
75109fa2f3
@ -19,7 +19,7 @@ class NbconvertFileHandler(IPythonHandler):
|
|||||||
|
|
||||||
@web.authenticated
|
@web.authenticated
|
||||||
def get(self, format, path='', name=None):
|
def get(self, format, path='', name=None):
|
||||||
exporter = exporter_map[format]()
|
exporter = exporter_map[format](config=self.config)
|
||||||
|
|
||||||
path = path.strip('/')
|
path = path.strip('/')
|
||||||
os_path = self.notebook_manager.get_os_path(name, path)
|
os_path = self.notebook_manager.get_os_path(name, path)
|
||||||
@ -52,7 +52,7 @@ class NbconvertPostHandler(IPythonHandler):
|
|||||||
|
|
||||||
@web.authenticated
|
@web.authenticated
|
||||||
def post(self, format):
|
def post(self, format):
|
||||||
exporter = exporter_map[format]()
|
exporter = exporter_map[format](config=self.config)
|
||||||
|
|
||||||
model = self.get_json_body()
|
model = self.get_json_body()
|
||||||
nbnode = to_notebook_json(model['content'])
|
nbnode = to_notebook_json(model['content'])
|
||||||
|
Loading…
Reference in New Issue
Block a user