-
-
Notifications
You must be signed in to change notification settings - Fork 25
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
Add hast-util-merge
to the list of utilities
#24
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Welcome @viktor-yakubiv! 👋
Thanks for sharing!
Some thoughts:
- In the readme could you include some additional details? Some ideas:
- How to install the package (from NPM or GitHub)
- A small contained example of using the package in a script
- An example of what input document(s) and the output look like
- Description of what the options the plugin supports are
- It looks like there are tests, great! some ideas on enhancing these:
- include a
test
script in package.json so others know how to run the tests - include any test dependencies as
devDependencies
so others know to install them - Consider adding a GitHub action to automatically run and report test status https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs#building-and-testing-your-code
- include a
- It looks like this uses JSDoc TypeScript? Also wonderful! Some ideas:
- Consider adding a tsconfig file so others can build the types
- Consider adding TypeScript as a
devDependency
so others know what version to use - Consider adding a
prepack
script that runs if/when you publish to npm
- It looks like you have a very consistent code style, nice! Some ideas:
- It could be good to add a linter/stylechecker to ensure that is maintained. Prettier/ESLint/XO can be great options.
@viktor-yakubiv friendly ping 🔔 |
Hi @ChristianMurphy, thank you for the feedback and ping as well 🙂 I am familiar with all of those things and intentionally did not do them:
I would appreciate feedback about functionality and if you can see the use case for this package, also about software design, package exports, clarity of naming (of both functions and package itself). |
Understood, the list in syntax-tree is intended as plugins that other can use.
How would having code quality assurances "pollute" the repository?
Happy to, though that level of feedback needs clarity on what the project's: intent, usage, and how the testing works 😅 |
Currently, this is extra work for the sake of work. I doubt someone ever will contribute to this package. However, if someone does and I face code consistency issues, only then I will provide those. You can grasp the API from exports at the If this is not enough for the feedback, I will provide extended documentation. Please, highlight which of your points are the must to have this merged. Also, if you doubt that this package should be added to the directory, please bring your concerns ahead so we resolve those or at least I don't waste time on extra documentation.
|
I agree with @ChristianMurphy mostly. Maintainers may use whatever tools they want to maintain a project, but I think it’s good to set some criteria to include packages in this list.
|
This list is not a list of everything that ever existed. People can already use npm search and github search. This list is curated by us: tools we suggest folks (including beginners) to use. I want to recommend projects with thorough docs and tests. Things are going to be maintained for a while. That folks will collaborate on. |
Closing for now, thanks! |
Initial checklist
Description of changes
I propose an utility that merges two hast documents applying some heruistics. I wrote the utility for my own need and find it being raw. I would appreciate your feedback.