Skip to content

Refactor error messages #29

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

Merged
merged 3 commits into from
Mar 14, 2023
Merged

Refactor error messages #29

merged 3 commits into from
Mar 14, 2023

Conversation

cossssmin
Copy link
Member

This PR:

  • refactors the <push> tag error so that it takes into account empty name attributes
  • updates some path-related error messages to be more succint and give a little more context

Let me know what you think, thanks!

@thewebartisan7
Copy link
Collaborator

thewebartisan7 commented Mar 10, 2023

@cossssmin thank you for this enhancements!

To me looks all good.

I would just change how to include get function from lodash.

From:

const {get} = require('lodash');

to:

const get = require('lodash/get');

Since according to docs and this article here this method seem to reduce bundle sizes:

  • Full import: 256.4 KB
  • Curly brackets: 256.54 KB
  • Module imports: 142.39 KB

I didn't test but I notice a change in bundle size after this change ecd7d54

Although there is not much to worry about the bundle size in this case. It is a fixation of mine.

I will merge the PR and release by Monday the stable release if there are not any other feedback from you.

Thank you!

@cossssmin
Copy link
Member Author

Sure thing, will fix it now 👍

@thewebartisan7 thewebartisan7 merged commit 3d5123e into posthtml:main Mar 14, 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.

2 participants