Age | Commit message (Collapse) | Author | |
---|---|---|---|
2023-08-19 | refactor!: remove Span trait, just use Range | Martin Fischer | |
`std::mem::size_of::<Range<NoopOffset>>()` is 0 so there's no need to abstract over Range. | |||
2023-08-19 | refactor!: make Position generic over offset type | Martin Fischer | |
Previously Span was generic over R just so that it could provide the method: fn from_reader(reader: &R) -> Self; and properly implementing that method again relied on R implementing the Position trait: impl<P: Position> Span<P> for Range<usize> { .. } which was a very roundabout and awkward way of doing things. It makes much more sense to make the Position trait generic over the return type of its method (which previously always had to be usize). Which lets us provide a blanket implementation: impl<R: Reader> Position<NoopOffset> for R { .. } | |||
2023-08-19 | refactor: add default for S type param of DefaultEmitter | Martin Fischer | |
2023-08-19 | refactor!: remove current_is_appropriate_end_tag_token from Emitter | Martin Fischer | |
2023-08-19 | docs: remove `crate::` from link labels | Martin Fischer | |
2023-08-19 | docs: move `produce ("emit")` clue to Emitter doc | Martin Fischer | |
2023-08-19 | break!: merge Tokenizer::new_with_emitter into Tokenizer::new | Martin Fischer | |
The Tokenizer does not perform any state switching, since proper state switching requires a feedback loop between tokenization and DOM tree building. Using the Tokenizer directly therefore is a bit of a pitfall, since you might not expect it to e.g. tokenize `<script><b>` as: StartTag(StartTag { name: "script", .. }) StartTag(StartTag { name: "b", .. }) Since we don't want to make walking into pitfalls particularly easy, this commit changes the Tokenizer::new method so that you have to specify the Emitter. Since this makes new_with_emitter redundant it is removed. | |||
2023-08-19 | break!: remove Default impl for Attribute | Martin Fischer | |
2023-08-19 | break!: remove Default impls for StartTag and EndTag | Martin Fischer | |
2023-08-19 | fix(docs): StartTag is a start tag | Martin Fischer | |
2023-08-19 | fix(docs): Error::EndTagWithAttributes should be emitted by emit_current_tag | Martin Fischer | |
2023-08-19 | break!: remove StartTag::next_state | Martin Fischer | |
You shouldn't manually have to match tokens yielded by the tokenizer iterator just to correctly handle state transitions. A better NaiveParser API will be introduced. | |||
2023-08-19 | break!: remove set_last_start_tag from Emitter | Martin Fischer | |
2021-12-05 | spans: get rid of code duplication by introducing Span trait | Martin Fischer | |
2021-12-05 | rename internal emit_error to push_error (to avoid confusion with trait method) | Martin Fischer | |
2021-12-05 | refactor: match btree_map::Entry instead of using and_modify closure | Martin Fischer | |
2021-12-05 | spans: slightly refactor DefaultEmitter | Martin Fischer | |
2021-12-05 | spans: add spans to Token::Error | Martin Fischer | |
2021-12-05 | spans: fix spans for quoted attribute values | Martin Fischer | |
2021-12-05 | spans: support attribute values | Martin Fischer | |
2021-12-05 | spans: support attribute names | Martin Fischer | |
2021-12-05 | spans: make Emitter generic over Reader | Martin Fischer | |
2021-12-05 | spans: make Emitter generic over Span | Martin Fischer | |
2021-12-05 | introduce StartTag::next_state | Martin Fischer | |
Closes #11. | |||
2021-12-03 | fix new clippy | Markus Unterwaditzer | |
2021-11-24 | hello world | Markus Unterwaditzer | |