-
Notifications
You must be signed in to change notification settings - Fork 3
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
Code is getting ugly again... #4
Comments
I think Angular is culprit here, I would have done it in raw Javascript or maybe plain jQuery since mostly it's a XHR and we are not using dynamic binding, only client-side templating that could have been done with mustache or any other Javascript templating, but maybe better HTML Template tag that it's already supported by all current browsers except Internet Explorer. By refactoring the web app by using standard XHR and HTML Templates instead of Angular, it will need more work but page size will drastically decrease and code will be easier to understand and maintain :-) (Disclaimer: I'm honestly not an Angular developer, the few things that I've done showed me there's too much magic there for someone that likes to work low level and baremetal... ;-) ) |
I was thinking about just in jQuery however went with angular as its the standard for One app pages. That being said, I definitely have no problems removing the dependencies on it. It probably would be easier to maintain. Alright
|
👍
Are you talking about async.js (the library for parallize code), or about |
async.js parallize code. Though I'm currenlty using it as series https://github.com/formula1/NodeOS-Blog/blob/master/html/footerjs/cacheOrLoad.js The callback api is a bit ugly, however for now I'll leave it as is. I'm doing Item callbacks to reduce the amount of iterations done. I probably want to delete everything in memory after I use it as well, however outside of that this can be somewhat closed I'm not using the template tag due to ie, however, what I'm doing is basically the same thing
Btw, I created a big header at the top for europe ;) But obviously that is better off a little smaller. We can also have a setting to turn of cached requests if you want. So that it becomes optional |
On an obvious note, caching results also speeds up the page a ton. |
I think I may want to start bringing in async as a clientside dependency as well. However, that in turn increases the size of the api which already takes about 500 ms to load (far longer than it should)
The text was updated successfully, but these errors were encountered: