[{"data":1,"prerenderedAt":182},["ShallowReactive",2],{"project-1967961":3},{"id":4,"name":5,"line":5,"line_source":6,"title":7,"url":8,"domain":8,"maker":9,"posted_at":10,"year":11,"points":12,"comments":13,"rank_in_year":14,"shown_in_year":15,"top":16,"tier":17,"category":18,"subcategory":19,"format":20,"keywords":21,"reception":26,"sentiment":27,"stance_mix":28,"scored_comments":32,"aspects":33,"strip":37,"post_text":39,"what":40,"said":58,"maker_in_thread":104,"shape":115,"grid":119,"attempts":145,"same_week":146,"maker_shows":29,"maker_hidden":173,"reader_version":174,"card":175},"1967961","CSS Meta-Language in Javascript","title","Show HN: CSS Meta-Language in Javascript",null,"KeithMajhor",1291422064,2010,10,11,122,370,33,"shown","languages","css preprocessor library","library",[22,23,24,25],"css in javascript","css preprocessor","dynamic css","less sass alternative","mixed",-0.238,{"positive":29,"neutral":30,"mixed":31,"critical":30},1,2,0,5,{"idea":34,"performance":35,"execution":36},{"positive":29,"critical":29},{"positive":31,"critical":29},{"positive":31,"critical":31},[38,31,32,31,29,31,38,31,31,29,31],3,"This was an attempt to make css more accessible to javascript. It just happened to solve a lot of the same problems as less and sass as a side-effect. I'll start with a few examples and then break out the code and explain it...\n\nHere's a generic example:\n\n\n```\n    css \u002F\u002F Begin CSS\n\n    ( \"selector1\" )\n    ({\n        property1: value,\n        property2: value,\n        \u002F\u002F ...\n    })\n\n    ( \"selector2\" )\n    ({\n        property1: value,\n        property2: value,\n        \u002F\u002F ...\n    })\n\n    ; \u002F\u002F End CSS\n\n```\n\nSome less and sass features (Variables, Mixins, etc.):\n\n\n```\n    \u002F\u002F Variable\n    var text_",{"problem":41,"audience":8,"pricing":8,"motivation":47,"time_to_build":8,"stack":51,"openness":56,"stage":57,"team_size":57},{"value":42,"source":43,"evidence":44},"Makes CSS more accessible to JavaScript and gives less\u002Fsass-like features such as variables and mixins","maker",[45],{"id":46},"post",{"value":48,"source":43,"evidence":49},"Make CSS more accessible to JavaScript and allow dynamic style modification",[50],{"id":46},[52],{"value":53,"source":43,"evidence":54},"JavaScript",[55],{"id":46},"open_source","unknown",{"praise":59,"objections":68,"requests":82,"questions":87,"alternatives":92},[60],{"value":61,"source":62,"evidence":63},"Useful for mockups and consistent dynamic class styling","commenter",[64],{"id":65,"by":66,"text":67},"1968513","humblest_ever","That makes perfect sense. I really like that it changes the css for the entire class. This would have good applications for a mockup website, you could add elements, alter…",[69,76],{"value":70,"source":62,"evidence":71},"Style tag per selector may be wasteful and could hurt performance",[72],{"id":73,"by":74,"text":75},"1972295","electrichead","I suppose the trade-off is having a style tag for each selector, which seems wasteful, and I'm not sure of the effect on performance. Any benchmarks for a large-sized stylesheet…",{"value":77,"source":62,"evidence":78},"Breaks without JavaScript enabled",[79],{"id":80,"by":66,"text":81},"1968102","This is great. How are you licensing it? And what do you plan on for the cases where people have disabled JS?",[83],{"value":84,"source":62,"evidence":85},"Performance benchmarks for large stylesheets",[86],{"id":73,"by":74,"text":75},[88],{"value":89,"source":62,"evidence":90},"What license is it under",[91],{"id":80,"by":66,"text":81},[93,100],{"value":94,"source":62,"evidence":95},"jQuery",[96],{"id":97,"by":98,"text":99},"1968798","revorad","jQuery can act on future elements using the .live() function.",{"value":101,"source":43,"evidence":102},"LESS and Sass",[103],{"id":46},{"comments":32,"answered":30,"key":105},[106,109,112],{"id":107,"text":108},"1968176","You can use whatever license you want (MIT, BSD, etc.) This is geared towards applications that wouldn't work without JS anyway. But you could always degrade gracefully by…",{"id":110,"text":111},"1968829","That's sounds a lot like what I had in mind when I wrote it.",{"id":113,"text":114},"1972612","Each time a declaration section is added to a selector the contents of the corresponding tag have to be re-stringified. Having a single tag would require the entire style sheet…",{"commenters":32,"max_depth":116,"maker_replies":32,"first_comment_mins":117,"lifespan_hours":118},4,67,45,[120,122,124,126,127,129,131,135,138,141,143],[80,31,38,121,66,31],"maker\u002Fneutral\u002Fnone",[107,31,31,123,9,29],"project\u002Fneutral\u002Fdesign",[65,31,32,125,66,31],"project\u002Fpositive\u002Fidea",[110,31,31,121,9,29],[73,29,29,128,74,31],"project\u002Fcritical\u002Fperformance",[113,29,31,130,9,29],"project\u002Fneutral\u002Fperformance",[132,30,38,133,134,31],"1972355","project\u002Fneutral\u002Fexecution","sharkbrainguy",[136,30,31,137,9,29],"1972478","commenter\u002Fneutral\u002Fexecution",[139,30,31,140,134,31],"1972656","commenter\u002Fneutral\u002Fnone",[97,38,29,142,98,31],"project\u002Fcritical\u002Fidea",[144,38,31,128,9,29],"1968817",[],[147,152,156,160,165,169],{"id":148,"name":149,"points":150,"category":151},"1981160","ViddyJam",37,"creative",{"id":153,"name":154,"points":16,"category":155},"1983714","Shove","games",{"id":157,"name":158,"points":13,"category":159},"1976327","Invincibilitee","web_saas",{"id":161,"name":162,"points":163,"category":164},"1985127","hipchan",9,"consumer_social",{"id":166,"name":167,"points":168,"category":164},"1980371","Top Comment Highlighter",8,{"id":170,"name":171,"points":168,"category":172},"1984761","Help Amazon EC2 be a foremost supporter of WikiLeaks and Tor","security_privacy",false,"v2",{"id":176,"name":5,"line":5,"ai":173,"cat":18,"year":11,"points":12,"comments":13,"rec":26,"s":177,"top":16,"kw":178,"maker":9,"domain":179,"tier":17,"attempts":31,"strip":180,"url":-1,"mix":181,"praise":61,"objection":70,"sub":19},1967961,-0.24,[22,23,24,25],"","30501030010",[29,30,31,30],1793990868920]