Skip to content

Refactor error messages#29

Merged
thewebartisan7 merged 3 commits into
posthtml:mainfrom
cossssmin:refactor/errors
Mar 14, 2023
Merged

Refactor error messages#29
thewebartisan7 merged 3 commits into
posthtml:mainfrom
cossssmin:refactor/errors

Conversation

@cossssmin
Copy link
Copy Markdown
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
Copy Markdown
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
Copy Markdown
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