Hi, where is the best practice to put js, image, css files when you make component? I put them in the same directory as component is. Is it good practice? Or should they be in media directory?

Recommended Answers

Hi, where is the best practice to put js, image, css files when you make component? I put them in the same directory as component is. Is it good practice? Or should they be in media directory?

A lot of components will have a js/, image/ and css/ folder under …

Jump to Post

All 2 Replies

Hi, where is the best practice to put js, image, css files when you make component? I put them in the same directory as component is. Is it good practice? Or should they be in media directory?

A lot of components will have a js/, image/ and css/ folder under the root of the component. I believe it just depends on what you feel is the best structure.

Ok, I guess its best to have all in the same folder as the component code for simplicity.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.