foundation / foundation-sites

The most advanced responsive front-end framework in the world. Quickly create prototypes and production code for sites that work on any kind of device.
https://get.foundation
MIT License
29.66k stars 5.49k forks source link

Port Foundation's javascript modules to use ES2016 dependency management #9438

Closed kball closed 7 years ago

kball commented 7 years ago

We want to bring Foundation's JavaScript dependency management up to 2016.

Some challenges will include:

However, I think the benefits will far outweigh the costs. Among other items, this should fix https://github.com/zurb/foundation-sites/issues/7386 and make it way easier to integrate Foundation components into other systems. It will also lay the groundwork for easier refactoring of Foundation down the road (jQuery removal, I'm looking at you!)

kball commented 7 years ago

That's a really good point @DaSchTour, I'll make the update. Any other feedback/improvements you recommend?

kball commented 7 years ago

@DaSchTour update made... definitely would additional feedback.

DaSchTour commented 7 years ago

@kball for the first step I think this is enough. I personally always use export class, export function and so on. But that's a mater of taste. As I've seen the abstract plugin class I would love to make the move from this state to TypeScript. I think it's worth to take a look into the usage of this and _this and where arrow functions should be used. But I think this should be done in a further step of refactoring. With transition to TypeScript I would also suggest adding TSLint with their recommended settings. Running the fixer once will directly add a lot of good practice, but I think that will be only small style improvements. But as I said I would see this in a later step, to avoid breaking everything ;)

kball commented 7 years ago

An initial PR has landed at #9965! @DaSchTour and @gakimball would love your reviews & feedback, as well as anyone else who would like to take a look.

kball commented 7 years ago

9965 has been merged! This issue can be closed. Super excited about the possibilities this opens up.