Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Ghost
@ghost~54f494ed15522ed4b3dcafad
I am starting with the copy-all compiler and I am wondering, is module.exports.name shown anywhere? Or is it just an internal name?
Anachron
@Anachron
@dbashford will try to mess around with it. My first idea would be hooking it up in the register one that already exist for modules/compilers, like a small api layer that will pass the data through. But I have to check mimosas internal working more, especially when it writes back to harddisk.
David Bashford
@dbashford
it is mostly an internal name, but occasionally it'll show up in a log message. usually debug logging.
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
quick question, is there an easy config flag to turn on source-maps in the stylus config that I'm overlooking? I feel like I'm just missing where it's documented.
David Bashford
@dbashford
Don't think I ever implemented stylus source maps. We stopped using stylus ourselves so I stopped paying attention to whether or not they had managed to figure out how to do them. It was an open issue for a very very long time.
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
It's just a flag that needs to be passed according to their docs, that's why I was curious because I feel like it should be simple
I can hack it in express but I'd prefer to keep all the JS and CSS compiling with Mimosa's standards ootb
if it's possible
David Bashford
@dbashford
could you toss an issue into mimosa-stylus for this? I can knock it out next spare moment I get. I agree, should be fairly easy to add.
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
okay awesome, will do, thanks @dbashford
David Bashford
@dbashford
:+1:
David Bashford
@dbashford
@boltforge wrapped up the stylus source map stuff last night, give it a go and let me know if you have any trouble.
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
@dbashford looks good man, quick question, does it take only a boolean, or a boolean || config object like the Stylus spec states?
just might good to specifically note that if not so people don't spin on it, I can put in a ticket if it helps
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
This message was deleted

Hmmm still not showing the sourcemaps for me...

exports.config = {
    modules: [
        "bower",
        "copy",
        "jade",
        "stylus",
        "react",
        "require",
        "server",
        "client-jade-static",
        "server-template-compile",
        "live-reload",
        "server-reload",
        "web-package"
    ],
    bower: {
        watch: true,
        bowerDir: {
            path: ".mimosa/bower_components",
            clean: false
        },
        copy: {
            enabled: true,
            trackChanges: true,
            outRoot: null,
            exclude: [],
            unknownMainFullCopy: true,
            mainOverrides: {
                "font-awesome": [{
                        "fonts": "../../font"
                    },
                    "css/font-awesome.css",
                    "fonts/fontawesome-webfont.ttf"
                ]
            },
            strategy: "packageRoot",
            togetherRoot: "components",
            forceLatest: true,
            pathMod: []
        }
    },
    serverReload: {
        watch: ["server.js", "server.ls", "server.iced", "routes", "src", "lib", "/assets/javascripts/json/data.json"],
        exclude: [],
        validate: true
    },
    stylus: {
        lib: require('stylus'),
        extensions: ["styl"],
        use: ['nib'],
        import: ['nib'],
        define: {},
        includes: [],
        sourceMap: true
    },
    clientJadeStatic: {
        context: {},
        outputExtension: '.html',
        extensionRegex: /.html.[a-zA-Z]+$/,
        prettyOutput: true
    },
    react: {
        lib: undefined,
        extensions: ["jsx"],
        options: {
            harmony: false,
            sourceMap: true
        }
    }
};

Anyone see anything I'm missing that would prevent it from working?

blob
I have it enabled in Chrome too so I'm kind of scratching my head atm...
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
This weekend I'll back out stylus control from the mimosa config and hardwire it with Express and see if that works, that will isolate the issue to Mimosa and then I can work from there, but I want all my preprocessor config through Mimosa as much as possible :shipit:
David Bashford
@dbashford
if you could, look at the compiled .css, does it have an inlined sourceMap at the bottom?
As far as the various options go, as a whole I'm moving away from supporting source maps as separate files. So I just force it to inline.
that is widely supported at this point
also, make sure you remove the node_modules/mimosa-stylus to force the reload of the latest module. Or you can update your modules list to have mimosa-stylus@1.4.0
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
yeah, I'm using the latest version, it's all good, even going the standard supported way doesn't seem to be working, but I am getting the linenos
{
  "name": "mimosa-stylus",
  "version": "1.4.0",
But not seeing the sourcemap file being created, or the sourcemap ref being created at the bottom of the css file
My naming conventions are good enough and the code is organized enough that it's really overkill, at the same time I want it there for when the more junior or new people start looking into the code
David Bashford
@dbashford
you running mimosa watch?
Daniel Bartholomae
@dbartholomae
Hi there, I am currently struggeling with getting mimosa to work with requirejs on the server side:
When requirejs looks for modules, it uses the mimosa build dir as working directory instead of the project directory. Any ideas how to change this? :)
David Bashford
@dbashford
So you are using AMD within your server code as well as your UI code? mimosa-require definitely looks at the watch.sourceDir as do pretty much all the modules. Your options are probably 1) Get your server and UI code both within the watch.sourceDir or 2) run two projects, one for server, one for UI. Future releases will allow having a single project with entirely different profiles running differently on different folders, but for now its a single input folder.
Daniel Bartholomae
@dbartholomae
For the first solution, do you expect problems if I use jade for server and client? The server templates might get rendered to the client templates.js, if I understand mimosa correctly
Daniel Bartholomae
@dbartholomae

I managed to shim it with this configuration:

exports.startServer = (config, callback) ->
  requirejs = require 'requirejs'

  requirejs.config(
    nodeRequire = require
  )

  requirejs ["#{__dirname}/app"], (app) ->
    app.startServer config, callback

Thanks for Mimosa, it really helped me to get started on NodeJS! :)

David Bashford
@dbashford
:+1:
hahahahahahahahahahahahahahahaha
@hahahahahahahahahahahahahahahaha
does anyone else prototype over HTTPS rather than HTTP?
curious if anyone would like a flag in a skeleton for a BS certificate but eh LOE is low but ROI is also low lol
David Bashford
@dbashford
so I'm down to 5 files to test and convert, but they are the biggies.
Daniel Bartholomae
@dbartholomae
Hi there, one quick question: Is it possible to create a mimosa module that does something with a file outside the watched dir (e.g. assets)? I would like to write a module that automatically copies all .coffee files from /app/shared to /assets/javascript/shared before they are compiled, but I'm not sure this is possible.
David Bashford
@dbashford
Check this out and see if its close to what you need? https://github.com/dbashford/mimosa-import-source If not then at least its a good place to start a conversation. =)
Daniel Bartholomae
@dbartholomae
Great, that's exactly what I was looking for! :)
David Bashford
@dbashford
:+1:
Ken Carpenter
@mindjuice
Has anyone come across this issue with mimosa-browserify? JonET/mimosa-browserify#21
It crashes every time I rebuild
Or rather every time mimosa rebuilds after noticing a file change.
David Bashford
@dbashford
Not a browserify shop here, so not something I've seen.
that module hasn't changed in awhile, what may have changed for you locally? or may the versions have shifted because they were not pinned?
Ken Carpenter
@mindjuice
I'll check to see if anything else has been updated recently...thanks. Every once in a while, it actually works properly, so not sure if I was just getting lucky before.
Anachron
@Anachron
@dbashford how's it going? =)
David Bashford
@dbashford
Good! Was actually just getting some mimosa core stuff done for the first time since last weekend. Work has been killing me. But am on trip to SF this week, will get to be productive via travel.
Anachron
@Anachron
Sounds great! Which IDE are you using btw? (I would guess TextMate) I'm trying out VIM, but it's still very hard for me compared to GUI-Tools like Atom.io.