-
Notifications
You must be signed in to change notification settings - Fork 1
[Review] Optimal performance & supportability #12
Copy link
Copy link
Open
Labels
Good first issueThis is a good starting point. Get involved - give these ones a go!This is a good starting point. Get involved - give these ones a go!enhancementNot a bug, but not a new feature - an improvement to what existsNot a bug, but not a new feature - an improvement to what existsfurther info requiredFurther information is required - either detail missing, or clarification is neededFurther information is required - either detail missing, or clarification is neededhelp wantedExtra attention is neededExtra attention is needed
Milestone
Metadata
Metadata
Assignees
Labels
Good first issueThis is a good starting point. Get involved - give these ones a go!This is a good starting point. Get involved - give these ones a go!enhancementNot a bug, but not a new feature - an improvement to what existsNot a bug, but not a new feature - an improvement to what existsfurther info requiredFurther information is required - either detail missing, or clarification is neededFurther information is required - either detail missing, or clarification is neededhelp wantedExtra attention is neededExtra attention is needed
I'm going to keep this issue open for a while, just until the repo has settled a bit. Any performance-related improvements, pop a comment down below and I will add them to this list.
Current areas for improvement:
forloops (resolved in [RELEASE] v0.0.5 #11)ifs (some nested unnecessarily) (resolved in [RELEASE] v0.0.5 #11)console.logalternative? Stripped most out of them from the primary scripts (non-min and min) - only concern here is impact to mobile devices. No "data" is being shared at all! (resolved in [RELEASE] v0.0.5 #11)loadMyScriptfunction - move into helper functions? (resolved in [RELEASE] v0.0.5 #11)scripttobody- is the current method the best method for all devices (not just desktop, but mobile too)? (https://jsperf.com/create-element-direct-append-vs-get-elements/1)var,letorconst?if's - are they being handled in the best way in general?switch/caseor continue withif else(https://jsperf.com/switch-case-vs-if-else/13)ifs within thecheckingfunction. See https://github.com/willstocks-tech/dynamically-polyfill-features-for-a-script/blob/develop/dynamicpolyfill.js#L40+L46dynamicPolyfillhas become potentially "Cognitively Complex" (see: https://codeclimate.com/github/willstocks-tech/dynamically-polyfill-features-for-a-script/pull/19)