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

refactor: rewrite ReportGenerateRow in React #583

Merged
merged 2 commits into from Jan 8, 2023

Conversation

yudukikun5120
Copy link
Collaborator

@mkobayashime I'd to hear your impression of the reimplementation using React (e.g. whether the not over complex manipulations like ReportGenerateRow should be implemented with plain DOM API or React).

@mkobayashime
Copy link
Member

mkobayashime commented Jan 7, 2023

@yudukikun5120
I think a disadvantage of using React over the pure DOM APIs is it makes the final bundle size bigger and loading time longer (in this case contentScript/reportTemplate.js will include the whole React runtime) in general, but we can virtually ignore it when it comes to Chrome extensions where all assets are downloaded/saved in the local disk beforehand, so we can use React without hesitation (this also is a reason why I chose React instead of Preact). Please note that this doesn't mean all existing DOM modification codes have to be rewritten with React: we can still use pure DOM APIs for simple manipulation and rewrite them when it become too complex to be done with pure DOM APis.

@yudukikun5120 yudukikun5120 force-pushed the refactor/reacty-report-template-generator branch from 3c8c511 to 4cb43cd Compare January 7, 2023 18:54
@codeclimate
Copy link

codeclimate bot commented Jan 7, 2023

Code Climate has analyzed commit 4cb43cd and detected 0 issues on this pull request.

View more on Code Climate.

@yudukikun5120 yudukikun5120 merged commit 8c6dced into main Jan 8, 2023
@yudukikun5120 yudukikun5120 deleted the refactor/reacty-report-template-generator branch January 8, 2023 07:16
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.

None yet

2 participants