Skip to content
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

refac(purify): Refactoring purify #849

Merged
merged 1 commit into from
Aug 10, 2023
Merged

Conversation

ssi02014
Copy link
Contributor

@ssi02014 ssi02014 commented Aug 9, 2023

Summary

Hello 👋, @cure53
I've improved some repetitive code and changed variable locations

Tasks

  • Refactoring Purify


arrayForEach([MUSTACHE_EXPR, ERB_EXPR, TMPLIT_EXPR], (expr) => {
content = stringReplace(content, expr, ' ');
});
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be a love/hate thing. I think your thoughts will be important. 😂 @cure53

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it 🙂

let attr = null;
let value = null;
let lcName = null;
let l = null;
Copy link
Contributor Author

@ssi02014 ssi02014 Aug 9, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my opinion, moving the variables inside the "while" block would make the code more predictable.

@cure53 cure53 merged commit 2b012d2 into cure53:main Aug 10, 2023
6 checks passed
@cure53
Copy link
Owner

cure53 commented Aug 10, 2023

Awesome, thanks :)

@ssi02014 ssi02014 deleted the refac/purify branch August 10, 2023 16:38
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