mleibman / SlickGrid

A lightning fast JavaScript grid/spreadsheet
http://wiki.github.com/mleibman/SlickGrid
MIT License
6.82k stars 1.98k forks source link

requirejs #815

Open reharik opened 10 years ago

reharik commented 10 years ago

Hey, I'm having a hell of a time getting slickgrid injected into my module via requirejs. I could show you my config but I"ve tried so many things that I wouldn't know where to start. I mean, I will if you want me too, but if you can just tell me the proper way to do it some of my hair might grow back.

mleibman commented 10 years ago

What does this have to do with SlickGrid? I mean, I don't know much about RequireJS, but SlickGrid is used just like any other JavaScript component - you include the script and associated resources on the page. How you do that is up to you, and if you're using one of the module loaders like RequireJS, that's more of a question for the RequireJS community.

I know some projects ship with built-in support for one or more of these module loaders, but that's not the direction I want to take SlickGrid. I believe that the choice and the responsibility of how to package and deliver the binaries should reside with the individual application developers.

reharik commented 10 years ago

Ah. Point taken. But perhaps you could help me understand the chain of dependency as that is probably where I'm having trouble with require. I mean I know that grid probably depends on core, but I think they both depend on jquery.dragable?. If you can just let me know that grid depends on these files and core on these etc. that would be great. Thanks, r

mleibman commented 10 years ago

The bare minimum is jQuery, jquery.event.drag, slick.core.js, slick.grid.js, and slick.grid.css. jQuery UI "sortable" is required if you enable column reorder. The DataView, formatters and editors are needed if you do use them. Same with controls and plugins.