Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

@import "folder/name"; error WHY?

Guys, I wrote in application.scss

@import "base/index";

but there's error in the application.css:

Error: Invalid CSS after "@import ": expected file to import (string or url()), was "‘base’;" on line 1 of scss/base/_index.scss from line 4 of scss/application.scss

1: @import ‘base’;

and terminal as well:

error scss/base/_index.scss (Line 1: Invalid CSS after "@import ": expected file to import (string or url()), was "‘base’;")

It's the same for the others import files, but not if I import from the same folder of application.scss, like that: @import "style";

@import url("base/index");

Thanks John Carty! But if I write url("base/index"), in the application.css there isn't any code but just @import url("base/index"); like the .scss file

I found the problem (stupid as ever): it's the sintax in index.scss file. I imported _base.scss partial file in _index.scss (as the video) but I didn't check the difference between the sintax in this video "Finishing and Importing our Partials, minute 6:17" (@import 'base';) and Brackets (@import "base";) So... not '' but ""

I don't know why in this video they use this sintax...

:)