Comments (4)
https://github.com/markdown-it/markdown-it/blob/master/docs/architecture.md#renderer
You can override existing renderer, this feature already exists.
from markdown-it.
Is the proper way to do this to override link_open (and image) in the renderer with a version that resolves the url?
It seems more appropriate to modify the token data at an earlier stage, so that any other custom rules will get resolved URLs.
from markdown-it.
You can do it in core
chain too. https://github.com/markdown-it/markdown-it-for-inline
It's up to you - depends on your needs.
from markdown-it.
I overrode link_open, but am only modifying the token and passing control on. I'll modify image after I refactor the code.
This should let other overrides work as long as the ordering is correct.
https://github.com/dwaite/wintersmith-markdown-it/blob/master/index.coffee#L28-L55
from markdown-it.
Related Issues (20)
- markdown-it with mermaid HOT 1
- Custom rule pushed as last in the chain is not being executed HOT 2
- 渲染内容丢失代码
- Need suggestion please ASAP
- [plugin:vite:vue] Element is missing end tag. HOT 2
- Open links in new tab HOT 2
- Incorrect conversion of numeric character references HOT 4
- Centralise indented code block checks HOT 10
- Capture link reference labels HOT 1
- Non-spaced indented entirely automatically numbered lists do not render, and spaced lists do not render correct subsequent line spacing. HOT 3
- Some images in base64 format cannot be rendered. HOT 1
- HTML comment tags break Markdown list indentation HOT 1
- Problems with single and triple backtick formatting HOT 1
- Rules with duplicate names is an issue HOT 1
- Markdown It Broken On Non-Node Environments (Cloudflare Workers) HOT 1
- Highlight.js + markdown-it is not working HOT 7
- Support for Function Plotting in Markdown HOT 1
- Maintenance status of markdown-it HOT 19
- Build Failing for Commit 2b6cac25823af011ff3bc7628bc9b06e483c5a08 HOT 1
- Invalid HTML produced when using <pre> tag in html mode HOT 4
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 markdown-it.