Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS How do I create optional arguments for a SASS mixin?

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #170952
    nixnerd
    Participant

    I’ve been casually trying to figure this out for awhile. I’d love to be able to have a mixin that can have anywhere from 1- infinity arguments, depending on what I might need in that particular circumstance. How can I accomplish this? I KNOW there’s a way! Any help is always appreciated.

    #171003
    nixnerd
    Participant

    For those curious… the official docs on this sort of thing:

    http://sass-lang.com/documentation/file.SASS_REFERENCE.html#variable_arguments

    Yay… @keyframes mixins here I come!

    BTW,
    I know that Compass or Bourbon probably have ready-made solutions for this… sometimes it’s nice to write custom stuff though.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.