-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Road to 1.0 #442
Comments
First of all, the points related to my modules:
The only missing selectors right now should be positional jQuery extensions (
I think I'll move the parser & tokenizer part of
That should also be already fixed (eg. brackets in attributes). Implementing the HTML5 treebuilder algorithm would be nice, though (but requires more time than I currently have).
It's now possible to enable the DOM 1 API, contributed by @jugglinmike to |
The stream interface is a great idea, but I don't really know how it will fit into the existing structure of cheerio. I have some ideas, I'll write about it tomorrow. Maybe it might be worth honoring the npm philosophy (a bit) and moving some components to their own module (eg. the serialization stuff). @matthewmueller How would you feel about creating a Github organization for cheerio and related modules? |
great idea, I've created the org: https://github.com/cheeriojs and made you guys owners. |
(Closed it by accident, sorry.)
jdalton published the individual functions of lodash as separate modules. We aren't using many functions, so replacing lodash with those modules might be worth to consider. |
i think we can do this now, but it'd be cool to be able to override the API methods. So we could have a module that makes |
I'd probably be fine with @jdalton's individual lodash functions, I really just don't like the |
Yup. If someone doesn't pass a primitive, it should be their problem. Wrapper objects are annoying as hell and shouldn't be used anyway. |
Many of Lo-Dash methods support ".where"_ and ".pluck"_ callback shorthands. So for example if you wanted to check if all the elements were disabled you could do: _.every(elements, 'disabled'); |
@jdalton oh that's awesome. I guess the big thing is making sure it's compatible with jquery. But we could extend and just pass the values into those functions. |
Okay, what I wanted to write about the stream API: As before, Chain methods such as I'm still not sure how to pursue
The second solution is much nicer internally, especially as it honors the streaming idea. It should also be possible to implement both variants (by having a Operations that return only a fixed sized set of elements ( It would be nice to support CSS 3's As a simplification, only leaving a node could fire an event, containing the node and it's level (the position in the stack). It's then possible to subscribe to As soon as a user-provided function is executed, it might be best to delay execution until parsing is done. A special case might be passing a generator function, which results in Additionally, it might be nice to add some of the streaming methods from |
Just checked off "Rename internal attributes to match their DOM keys (type => nodeType)" since #561 has landed |
Any word on |
haha, i'm not sure these are going to get done without some new love at this point. as far as i can tell cheerio is quite stable though. you guys want to bump it? |
IMHO #863 would be a good place to bump it, as people will have to actually check their code. Or should we release v2 at that point? |
Is this still the todo list before v1.0.0 is stable? I would like to help it get over the bump. |
This is woefully out-of-date (2014!!) Streaming didn't make it in 1.0.0. I think it's tricky but doable. The main issue is that you're now working with partial DOM trees. Unfortunately nobody spent time on it. I'd welcome any attempts to spec it out though! |
@matthewmueller Is there a way I can help? It seems like a lot of open issues are irrelevant. What needs to be completed to release v1.0.0? |
@UziTech this is the TODO list: https://github.com/cheeriojs/cheerio/projects/1#card-23270619 |
Jotting down some quick thoughts of what I'd like to see to make 1.0 awesome:
Must haves:
Nice to haves:
What are your thoughts? Anyone else have anything they'd like to see?
/cc @fb55 @davidchambers @jugglinmike
The text was updated successfully, but these errors were encountered: