simison / bootstrap3-less

(deprecated) Bootstrap 3 for Meteor, with Less.
60 stars 19 forks source link

Less compiler error #27

Open joystick opened 10 years ago

joystick commented 10 years ago

Hi, I have following error:

While building the application:
client/views/venues/venues_new/venues_new.less:7:2: Less compiler error: .make-row is undefined

It happens when I do:

.new-venue {
    background: yellow;
    .make-row();
}

Please advise what can be wrong.

Thank you, Alexei

Nemo64 commented 10 years ago

you probably haven't included the mixins.less of bootstrap.

Do you use the Advanced Usage? If so, you need to @import your variables.import.less in every file which uses bootstrap mixins or variables.

joystick commented 10 years ago

Hi Nemo64, thanks for reply. I use steps 1 - 4 from here. My /client/app.less contains @import "/packages/bootstrap3-less/bootstrap.import.less"; only. This imported less file contains import directives for variables, mixins and rest of the stuff. Shouldn't mixins be imported and available?

Nemo64 commented 10 years ago

Ok.. so you import bootstrap in /client/app.less and then use a mixin in client/views/venues/venues_new/venues_new.less, right?

That sadly won't work because every .less file has its own scope of variables. You have 2 options:

You could also import bootstrap in every less file but than you have multiple instances of it, which you should avoid.