Comments (6)
I'm more interested in Notion to HTML right now anyway (for my blog content) though from looking at kjk's Go implementation might be a pain to rewrite in Python.
Took a stab at this here! Would you be able to take a peek and provide feedback? Curious whether this is the sort of thing you'd find useful.
#91
from notion-py.
https://github.com/Cobertos/md2notion may be of use, it will convert full Markdown documents to a descriptor for notion-py
from notion-py.
@Cobertos Awesome! Let me know if you want to look at tighter integration of md2notion into notion-py (and then I could add you as a co-maintainer). Would be nice to have a clean interface for the other direction as well (e.g. myblock.to_markdown(recurse_depth=2)
).
from notion-py.
@jamalex Hmm, possibly. I kind of like the separation tbh. Allows me to provide a CLI interface and keeps the focus of both libraries more focussed.
I also would hope Notion's Markdown importer would eventually get better so my package is unneeded and they'll just have an API endpoint you can hit to do a proper import instead x:
I've been looking at going the other way though (Notion to MD) but the surface area of Notion block types is much larger than what MD can handle. I'm more interested in Notion to HTML right now anyway (for my blog content) though from looking at kjk's Go implementation might be a pain to rewrite in Python.
from notion-py.
@Cobertos md2notion
is great to see - nice job. I've needed that functionality in the past and will give it a try in the future.
from notion-py.
@Cobertos Sounds good. If there's anything you find yourself doing in md2notion that you think could benefit general upstream notion-py users, please do open a PR! :) I've added a link to md2notion from the README.
Yeah, markdown definitely can't handle everything. HTML could be interesting, and some sort of framework for exporting to custom HTML (templated, with customizable transformation functions for different block types) could be pretty nice. I don't think it would be particularly hard to get set up, leveraging notion-py's existing interface?
from notion-py.
Related Issues (20)
- HTTPERROR using children.add_new
- collection.add_row() fails on new databases HOT 2
- How to set database column calculation?
- Not documented: how to set the size of an image HOT 1
- > this is a pretty paralyzing issue. does anyone know how long it will take for it to get merged in? HOT 1
- Uploading image doesn't work HOT 2
- Need to cut a new release
- Notion crashes when setting CollectionView filter with no id HOT 2
- Is this module still work now? I got an error, outdated? HOT 1
- Failed To Run "setup.py" Due To Encoding Error
- requests.exceptions.HTTPError: Invalid input from client.get_block HOT 8
- Unsaved transactions: SpaceShardRecordPointer have no space id HOT 1
- raise InvalidNotionIdentifier(input_value)
- Help!!! requests.exceptions.HTTPError: Invalid input. HOT 4
- TypeError: Retry.__init__() got an unexpected keyword argument 'method_whitelist' HOT 3
- Client POST generates a HTTPError HOT 1
- (question) is there `get_all_comments`? HOT 1
- notion_client.errors.RequestTimeoutError: Request to Notion API has timed out
- HTTPError (400) when trying to load a database despite trying proposed solutions HOT 3
- Search (and find best matching page titles)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from notion-py.