Monday, June 3, 2024
 Popular · Latest · Hot · Upcoming
-2
rated 0 times [  1] [ 3]  / answers: 1 / hits: 18787  / 9 Years ago, thu, september 17, 2015, 12:00:00

In the ember-cli folder structure where should I put images?



/app
/bower_components
/config
/dist
/node_modules
/public
/tests
/vendor


I am using ember-cli version 1.13.1.


More From » ember.js

 Answers
39

Create a folder inside public -> public/assets/images/, and place your images inside. You can then access them in the browser using /assets/images/imagename.png



Source from the ember-cli documentation it states:



Raw Assets



public/assets vs app/styles
To add images, fonts, or other assets, place them in the public/assets directory. For example, if you place logo.png in public/assets/images, you can reference it in templates with assets/images/logo.png or in stylesheets with url('/assets/images/logo.png').


[#65029] Tuesday, September 15, 2015, 9 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
janiajohnnad

Total Points: 146
Total Questions: 92
Total Answers: 107

Location: Faroe Islands
Member since Thu, Apr 8, 2021
3 Years ago
;