Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    kevin olson
    @acidjazz
    hmm ok so gitter is properly highlighting stylus
    kevin olson
    @acidjazz
    im messing around wtih the .define in stylus
    this mean i can pass variables/objects to stylus to reference?
    kevin olson
    @acidjazz
    something like
          stylus(post.data, post.options).define('bob', 'suzy').render(function(error, output) {
    
            if (error) {
              res.writeHead(500, {'Content-Type': 'text/html'});
              res.end(error.message); 
            } else {
              res.writeHead(200, {'Content-Type': 'text/html'});
              res.end(output);
            }
    
          });
    how do i access bob in stylus?
    kevin olson
    @acidjazz
    so i figured out how to access bob, but now my issue is what if suzy was an object, like suzy.q.title
    suzy['q']['title'] doesnt work nor suzy.q.title nor #{suzy.q.title} etc
    kevin olson
    @acidjazz
    i still cant figure out how to access these other dimensions of these passed in objects
    kevin olson
    @acidjazz
    anyone around? now having issues concatenating variables like {a}{b} etc
    bruce
    @sqram
    Can i assign a media query to a variable?
    for instance, something like
    $iphone-6 = @media screen and (max-device-width : 687px)
    kevin olson
    @acidjazz
    I don't see why not, maybe just try?
    bruce
    @sqram
    i did and didnt work
    bruce
    @sqram
    quote or no quotes, doesnt seem to work
    kevin olson
    @acidjazz
    Hmm.. how exactly does .set() work in stylus?
    kevin olson
    @acidjazz
    hmm found an interesting bug stylus/stylus#1286
    Ah this is y issue: stylus/stylus#1405
    Wow this is a huge deal
    Garrick Cheung
    @GCheung55
    Has anyone had issues with conflicting @import/@require module names?
    And how did you address it?
    I'm getting a conflict with bootstrap-stylus mixins folder.
    kevin olson
    @acidjazz
    @GCheung55 bootstrap nooo. try nib
    Jeff Lupinski
    @lupinskij
    Any work arounds for map-get?
    Garrick Cheung
    @GCheung55
    @acidjazz I've been using nib but I'm using bootstrap because im not starting from scratch.
    Michael Fellinger
    @manveru
    anybody know how to get stylus working via jspm?
    Daniel Bartholomae
    @dbartholomae
    Hi there, how can I @extend .class-name if .class-name is defined in a separate .css file?
    kevin olson
    @acidjazz
    I like how stylus got a new web site
    who did it?
    Daniel Bartholomae
    @dbartholomae
    Hi there, just wondering: why doesn't stylus use semver? :)
    Daniel Bartholomae
    @dbartholomae

    Another thing:

    a = {}
    a.b = test

    seems to work, but

    a = {}
    a.b ?= test

    doesn't. Any way to fix this?

    kevin olson
    @acidjazz
    what's semver
    semantic versioning?
    Daniel Bartholomae
    @dbartholomae
    Yes. Basically it means that as long as the first part of the version number doesn't change, there are no breaking changes.
    Ilya Kantor
    @iliakan
    Hi
    What's the community-approved way to implement cache busting with url() ?
    a custom url function? a wrapper around resolver?
    Andrew Bradley
    @cspotcode
    I have a custom stylus function that accepts a path to an image file. I want to pass a relative path, but the invocation and implementation of the function are in different files/locations. Is there a function to resolve paths in my .styl file?
    comp(imagePath)
        background: url(imagePath)
        size = image-size(imagePath)
        background-size: (size[0] / 2) (size[1] / 2)
    Karter
    @Krter
    hi stylus users any one here using jeet
    Andrew Bradley
    @cspotcode
    Yeah, I am
    ( @Krter )
    Karter
    @Krter
    Hi @cspotcode sorry for late reply
    Karter
    @Krter
    @cspotcode I'm using jeet in my project I'm facing few issues
    R u free for answer @cspotcode
    Andrew Bradley
    @cspotcode
    General tech support rule of thumb: Don’t ask to ask. Ask the question and someone will answer if they’re able.
    Karter
    @Krter
    Hmm
    Sébastien D.
    @demsking
    Hi

    Why this code does not work?

    div
        $length = 28px
        width: ceil(sqrt(2*$length*$length))
    Error: /home/user/node/lib/node_modules/stylus/lib/functions/index.styl:55:12
       51| // Rounding Math functions
       52| 
       53| ceil(n, precision = 0)
       54|   multiplier = 10 ** precision
       55|   math(n * multiplier, 'ceil') / multiplier
    ------------------^
       56| 
       57| floor(n, precision = 0)
       58|   multiplier = 10 ** precision

    How to fix it?

    Covington Doan
    @covingtondoan
    @demsking Instead of sqrt() did you try math(x, 'sqrt')?
    Sébastien D.
    @demsking
    @covingtondoan Its works, thanks :+1: