Comments (10)
I'm seeing this as well. 0.3.3 works, 0.3.4 does not. No errors other than the markdown source is rendered inside a single <p>
tag.
from angular-marked.
I see this as well. Marked 0.3.3 works well, but 0.3.5 has issues.
Currently I'm using it for mainly headings.
"##My Heading"
With v0.35 I have to change the string to "## My Heading"
from angular-marked.
My issue was resolved by the marked project owner. Marked was not following GFM correctly. They have updated to requiring a space after the # for headings.
from angular-marked.
@ascholz81 Did marked.js release the new version yet?
from angular-marked.
@ajielee @johnwebbcole The new version of marked requires a space after the hashes (markedjs/marked#642). Is this your issue?
from angular-marked.
@ajielee Why do you have a $scope.$watch
statement in your example? If you are using the directive you don't need to call marked
directly.
from angular-marked.
@Hypercubed Yes, that's the reason why I got the problem. But I don't agree with the GFM style, so I still hold marked.js#0.3.3. Thank you.
from angular-marked.
@Hypercubed Sorry for that block of code, which I forgot to delete.
from angular-marked.
@chjj recommends:
marked.Lexer.rules.gfm.heading = marked.Lexer.rules.normal.heading;
You might be able to do something like this using the setRenderer method.
from angular-marked.
GFM does not support headings such as: "##heading". Only the original markdown implementation does. Like @Hypercubed mentioned, either overwrite the rules or use gfm: false
.
If we were to change the GFM rules to accept headings like that, there would be another camp of people posting issues about incohesiveness with GFM, unfortunately. Personally, I don't think it's a big deal, but we're trying more to stick to GFM, however inconvenient it may be.
from angular-marked.
Related Issues (20)
- can custom rules be added? HOT 5
- List of all supported Markdown syntax rules HOT 2
- Not able to load json markdown HOT 6
- hljs highlighting not working HOT 4
- Unknown provider: hc.markedProvider HOT 4
- Use of ng-src HOT 4
- Convert scope.marked to String before using it as a string HOT 8
- How to use markdown for a contentful entry HOT 2
- Code blocks indented by tab HOT 1
- HTML tags in markdown are being stripped HOT 3
- Allow setting options per directive instance. HOT 4
- Tables not rendering HOT 3
- Unable to load in angular-seed app
- Could we support Angular2? HOT 4
- emoji not rendering HOT 2
- Replace marked with marked3 HOT 2
- Security issue in marked 0.3.6
- m.Renderer is not a constructor
- Overriding link renderer skips all the security work made by the default renderer
- Change the way `marked` is imported to keep IE11 support
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 angular-marked.