cassette
cassette copied to clipboard
Create a Cassette.Less package that references dotless.Core instead of dotless.ClientOnly
I'm trying to add Cassette to a site that references a library which already has a reference to dotless.Core. I can't delete the dotless.Core reference as the other library needs it, but I can't delete dotless.ClientOnly as Cassette needs it. Ideally there should be a Cassette.Less package for those of us already referencing dotless.Core.
@Daniel15 What's the issue exactly with having both dotless.clientonly and dotless.core in the same site?
They both have classes with the same name in the same namespace, so you get compile errors.
Regards, Daniel
Sent from my phone - please excuse any typos. On 13/05/2013 6:48 AM, "Artur Dorochowicz" [email protected] wrote:
What's the issue exactly with having both dotless.clientonly and dotless.core in the same site?
— Reply to this email directly or view it on GitHubhttps://github.com/andrewdavey/cassette/issues/379#issuecomment-17785045 .
I achieved this by copying Cassette.Less.csproj and Cassette.Less.nutrans to make Cassette.Less.Core.csproj and Casette.Less.Core.nutrans. Need to clean it up a bit (remove the duplication) but this should work. https://github.com/Daniel15/cassette/tree/dotless-core
I my opinion this is a problem with the dotless project. It would be much simpler if their packages didn't overlap, and instead had one reference the other. Maybe open an issue with them requesting this?
Thanks Andrew, I definitely agree with you and I'll raise an issue with DotLESS about it.
Regards, Daniel
Sent from my phone - please excuse any typos. On 13/05/2013 6:41 PM, "Andrew Davey" [email protected] wrote:
I my opinion this is a problem with the dotless project. It would be much simpler if their packages didn't overlap, and instead had one reference the other. Maybe open an issue with them requesting this?
— Reply to this email directly or view it on GitHubhttps://github.com/andrewdavey/cassette/issues/379#issuecomment-17798962 .
@Daniel15 I think that you only get the compilation errors when you use dotless types in your code, just referencing both dotless assemblies doesn't cause problems. I don't think that you need to reference dotless types when using Cassette so it must be required by the other library you mention. Could I ask what that library is?
You could maybe move code referencing dotless types to a separate project which references just dotless.core package. Just an idea.
DotLESS is used in an internal assembly in one of our systems at work. We have shared code for custom error logging and merging of variables from a database into a LESS file (used for client-configurable colours and fonts). This internal assembly references dotless.Core as dotless.ClientOnly didn't exist at the time we integrated dotLESS into our system.
As a potential work around for the time being you could switch to Cassette.LessJs which shouldn't have any overlap...yes a bit of bloat while things get fixed, but should work.