Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Book: document markdown filter #641

Merged
merged 2 commits into from
Feb 21, 2022
Merged

Book: document markdown filter #641

merged 2 commits into from
Feb 21, 2022

Conversation

Kijewski
Copy link
Collaborator

No description provided.

book/src/filters.md Outdated Show resolved Hide resolved
Comment on lines 394 to 406
```
let options = &ComrakOptions {
render: ComrakRenderOptions {
unsafe_: true,
..Default::default()
},
..Default::default()
};


{{ "<script>alert('Hello world')</script>"|markdown(options) }}
```
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe the usage example, should be more copy-pastable. I think it might be confusing, that it's half Rust and half Jinja :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 I added a link to the unit tests. I think this should be the most readable variant, esp. since it should not be too interesting to most users.

book/src/filters.md Outdated Show resolved Hide resolved
@djc djc merged commit 09429bb into rinja-rs:main Feb 21, 2022
@Kijewski Kijewski deleted the pr-book-markdown branch February 21, 2022 11:34
@djc djc mentioned this pull request Feb 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants