jedfoster / SassMeister

The Sass playground
http://sassmeister.com
199 stars 25 forks source link

@import other sassmeister gists #72

Closed xzyfer closed 9 years ago

xzyfer commented 10 years ago

More broadly it'd rad to include external resources. This would enable simulating things like filesystem or dependant libraries that aren't part of SassMeister.

JSFiddle enable this via their "External Resources" setting.

I think preprocessing (hijacking) @import would be an elegant way to deal with import SassMeister gists.

@import "gist/8595756"; // wget the gist and do some load path magic
jedfoster commented 10 years ago

See also issues #29 and #63.

I agree, would be cool. It's on my radar, but may be a while.

xzyfer commented 10 years ago

My bad. I did a quick search but nothing jumped out at me.

FWeinb commented 10 years ago

I think a custom importer is the way to go here: http://sass-lang.com/documentation/file.SASS_REFERENCE.html#custom_importers I just wrote one for SassyJSON and it is quite simple.

jedfoster commented 10 years ago

image

Excellent! I've been thinking about how to get around the filesystem requirements of the default importer, and this might be it. The main hurdle has been the lack of a "physical" filesystem—with the app's current architecture we only have access to the gems included in the bundle or resources fetched from remote sources via HTTP.

I'll look into this and I may have questions for you. Thanks!

FWeinb commented 10 years ago

Any news? Do you need some help?

jedfoster commented 9 years ago

I doubt this will ever happen. https://github.com/jedfoster/SassMeister/issues/63#issuecomment-72350041