nbdev
nbdev copied to clipboard
Allow a single notebook to export to multiple .py modules
Use the same #|export modname
syntax that was in nbdev1
The directives docs suggest this issue can be closed, no?
Maybe you could give it a try and see if it works? I don't recall where we got to with this.
It doesn't work in my simple example. The export directive silently fails, not exporting the function anywhere: nbdev-hello-world-test.zip
@hugetim it works in my example with nbdev Version: 2.3.13
01_two.ipynb:
# | default_exp two
#| export core
def foo_core_mixin(): # is exported to core.py
pass
#| export
def foo_two(): # is exported to two.py
pass
However, I don't like the fact that it appears that you can't have two notebooks with the same default_exp
(as it says here, it gets overwritten. However, i can't find anything in the docs about this)