UI Drama


It's been 6 years I have been working in front-end technologies. And, when I say "work", it means solving real life problems and not JUST creating web pages. At the milestone of 3 years, it was the time to evaluate libraries and frameworks, some good, some very complex but,  none was something you can use in any type application. 

Then, I thought why not to build my own framework that can be used in any type of application. I built a very simple and light weight framework which lets me include any available open-source library into my project, and I don't have to worry about all transitive dependencies. It does everything for me. It was very simple - npm->grunt->bower->Application.


And you know what, it is good for small applications as well as large applications. It has on demand-lazy-loading-feature by default. I was hardly facing any problem, never felt any need to become proficient in any of the so-called latest and popular frameworks. I would go check, read concepts, read docs and say "hun?" and back to my simple-stable libraries. And that's the beauty of work.

Recently, I thought why not to give it a try, why not to try to learn at least one of those frameworks?

Well, that's is how it started.

React : 

It says you don't need to worry about anything. We do everything for you.

Well, let's see.

They say drop everything, why use so many tools and libraries like bower, grunt and so & so.

Well cool. huh?
Let's start, they recommended to use some new tools.

A package manager, such as Yarn or npm. It lets you take an advantage of a vast ecosystem of third-party packages, and easily install or update them. No issue as I was already using NPM.

A bundler, such as webpack or Browserify. It lets you write modular code and bundle it together into small packages to optimize the load time.
A compiler such as Babel. It lets you write modern JavaScript code that still works in older browsers.
I did as they said, I started to get deeper and deeper into it, I am not the one who simply installs what docs say, I do need to know what it does, then it turned out, using babel you can skip webpack but, then you will need to manually add some more files to your project of babel, but then compiled files with babel will give you error like "require is not defined".

Let's see community support,  I asked do i need requireJS? 

Not necessarily, but you can should use browserify to support it.

Huh? another tool?

One smart solution - use AMD. They say by default, babel use common structure so let's convert it to AMD structure, then i see "define is undefined".

Huh!!

Comments

Popular posts from this blog

Localization vs. Internationalization