Code Monkey home page Code Monkey logo

Comments (6)

brianzelip avatar brianzelip commented on May 22, 2024

I understand where you're coming from @mrzool. I too got better w/ Sass via this project, and struggled with the v4 Rework learning curve. Part of my struggle included reverting to < v4 to continue w/ Sass. (Maybe that's a useful option for you in the short run?)

Then I just hunkered down and kept going over the Bass docs on using rework (and the rework docs and even that W3C working draft (linked from the rework-vars page) was helpful too). Getting used to using gulp if ur not already helps. There's not much to v4 other than initiating gulp and it'll do the rest on changes to css.

As for working w/ the Rework set up, the counterpart to the previous _variables.scss file is basscss/src/basscss.css. This is what is natively set up to start adding custom variables and overriding Basscss styles. Just follow the rework syntax here for :root to make new/override variables, and add whatever additional css you want.

The one disadvantage that I see in the new approach is that there's no one central place for all the variables that are at work w/ native Basscss (like there was w/ _variables.scss). Now the variables are spread out throughout all of the individual index.css files found in the directories found in the node_modules directory. You just have to keep going in and out of those dirs, and keep referencing stuff like http://www.basscss.com/docs/styles/ & http://www.basscss.com/docs/kitchen-sink/ to figure it out. Soon you'll start to get the hang of it just like you did w/ the Sass.

Happy hacking!

from basscss.

jxnblk avatar jxnblk commented on May 22, 2024

I'm sorry to hear that, @mrzool, but Basscss has always been more about CSS than any preprocessor. If you are using Sass, you can still include the compiled CSS file by renaming it to something like _basscss.scss. The biggest loss with that approach would be variables, but it's not that big of a file, and you could replace values with you're own variables where it makes sense.

That said, Rework is a better fit for Basscss, because of its plugin architecture and future-friendliness towards the CSS spec. There are many features and anti-patterns in Sass that will never likely become part of CSS, such as extends and mixins, and I think it's best to avoid encouraging the use of that sort of functionality as much as possible.

Although Sass is probably the most widely used preprocessor now, I'm not sure that will always be the case, and I do not want to support functionality that goes against the philosophy of Basscss's approach.

In the meantime, I am looking into build processes that would make working in Sass easier as well as simplifying and providing better documentation for using Rework.

And, thanks @brianzelip. That reminds me that I should add a centralized list of all available variables. As for the node_modules directory, those are all available as separate modules/repos (e.g. https://github.com/jxnblk/basscss-base) if you'd like to really customize what's in there.

from basscss.

mrzool avatar mrzool commented on May 22, 2024

Part of my struggle included reverting to < v4 to continue w/ Sass. (Maybe that's a useful option for you in the short run?)

@brianzelip Rolling back to version 3.1 is exactly what I did for the project I'm working on. Bass v4 looks amazing though, and I feel like I'm missing out on a lot of good stuff.

@jxnblk Thanks for sharing the thought process behind the redesign, I def get your point now and I'm all against the misuse of extends and mixins myself.

Can't help but missing the ease of use of the Sass version, though. Having a centralized list of all the variables in a single file was priceless, as was being able to see and appreciate the simple math behind all the magic. Also, that modular file structure was a big time saver for me. It was just straightforward and self-explaining, made understanding what was going on and where a breeze. On the other side, I don't really get Rework so far. Feels to me like a lot of complexity was brought in all of a sudden.

Anyway, don't get me wrong, you're doing a truly amazing job here and I'm grateful for how much I was able to learn from all this. You sure as hell know better than me, so I'll just close the issue now and STFU.

Y'all have a good night.

from basscss.

jxnblk avatar jxnblk commented on May 22, 2024

@mrzool my intent was not to make you STFU. This feedback is super helpful, and I'd like to make Basscss as straight-forward as possible. Personally, I think Rework is much simpler than Sass, it's just that the tooling is less mature and less widely used. I was a little unsure about switching because of Sass's popularity, but I'm hoping to make Rework a little less daunting for those less familiar with it.

I'll let you know if/when I have better support for Sass in v4 though.

from basscss.

jxnblk avatar jxnblk commented on May 22, 2024

Apparently I tagged the PR incorrectly, but scss partials are now available in the /scss folder.

from basscss.

mrzool avatar mrzool commented on May 22, 2024

This has seriously made my day. Thanks a lot @jxnblk, can't wait to peek into it.

from basscss.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.