I love open-source, seriously I really love open source. Back in May – Samuele said it would be cool to add Gulp support, Michaux submitted a Pull request to address it.
The problem we faced – was that we did not want to replace Gulp with Grunt but instead to provide choice to the developer what to use. What the tireless Drew did was to orchestrate this and extend the mean init command to provide some interaction using the inquiry node package.
This PR joined a bunch of others concerning adding SASS support or LESS support, working with other frameworks instead of bootstrap, or even working with different dbs.
We need to maintain a balance between focus/opinionated approach and providing choice. Express, Mongo and even Angular have alternatives and people want to use MEAN with different task-runners, databases and front end frameworks.
I’m excited for the first time we provide choice (on a much anticipated and requested feature) and see this as an important step forward as the framework grows and provides more versatile use-cases.
We’re getting ready to release 0.4.1 and have a branch (0.4.1rc1) for meanio and mean-cli which you can test it locally…
But hey – how do you do that anyway. Let review – Mean is combined of 3 parts
linnovate/mean-cli – Providing the cli commands + mean network access
linnovate/meanio – Core of the project
linnovate/mean – 5 core packages + configuration
When we install mean we initially install the mean-cli globally through
npm install -g mean-cli
When we run mean init – a linnovate/mean is cloned in to the directory you provided as you’re apps name. If we look at linnovate/mean/package.json – you see the dependency to meanio in the dependencies section. If we change the meanio that gets installed we’ll get the new capabilities.. The handy todo list by Yonatan can be helpful..
We offered to send some stickers and a shirt to that rad 8 yr old and we learnt her name was Daphne and that she liked coding with Ryan Carter her proud father. After a few weeks we got this cool pic showing Daphne with her ninja shirt in action!
I got a chance to visit the US two weeks ago and it appears that Daphne (and Ryan) live a few blocks away from my sister in Aurora Colorado (a Denver suburb). It was totally clear that we should meet and hack on some MEANingfull code together So we met up, scaffolded the pinkninja package (coming soon!!) and had a good time. I used this experience to personally announce that the mean.io ninja will be name Daphne – A cool js ninja with attitude.
Pixelated MineCraft Ninja
In the same evening I saw a post in Facebook that proved that indeed Daphne has super creative ninja powers when I saw the MineCraft version of Daphne the Ninja!
We’re waiting eagerly for the publication of the pinkninja package and also are happy with the “proud fathers” growing involvement with mean.io and help in facebook and in the google group. Rock on Carters!
Documentation is important.
It’s the way a developer perceives the value of an opensource technology, the mental checklist I use is
Skim the site.
Skim the docs.
Try to install in 5 minutes
Skim the code
If all four pass – dive in.
The docs we had were good but we where the only ones that maintained them. The code was in an angular view and was buried within the linnovate/meansite repository with hardly any contribution by the community.
We knew we needed the docs to be based on code from the repository and we knew we needed to have a way to simply merge a PR and get the docs out there.
Looking for open-source solutions I stumbled upon flatdoc which is a super easy way to build documentation upon the hierarchy of your README file. I built http://learn.mean.io as the new hub for documentation for mean.io.
What this means is that the community can directly contribute by submitting Pull Requests upon README.md and that we have developers more engaged in the docs and let the documentation team submit improvements on a much more rapid basis.
Documentation is #1 on my priority list these days and I feel we took a substantial first step in the right direction.
The next contributors to win the super prestigious 🙂 Ninja of the Month awards – are Andrija Petrović and Veljko Popovic which have initiated many ideas and improvements while refactoring the mean core and introducing the idea of core packages. Beyond enjoying geeking out and sharing linux kernel 2.0 war stories they have been doing an amazing job and are a big part of the performance and restructure imporvments coming up in release 4.1. To play around with that branch feel free to checkout the 0.4.1 branch – great job guys!
The current experience a developer has when he installs mean is welll… – terrible
Lets see what a developer that is all excited about the mean stack experiences and what probably goes through his mind…
Installs the system and thinks “That was a breeze, cool asciiart!”
He runs npm install and thinks “Why does this take so long? and why do they install so much stuff to bootstrap their application?
Runs grunt and goes to localhost:3000
Sees a page with – “This is the Homepage” and thinks… “Ok – now what??“
For that developer to actually figure out what the next steps would be he would need to.
Assume this is a boilerplate – We are trying to transition to a framework
Try to login to the site and fail (there is now existing users)
Try to register to the site (they used to fail until we retouched the social auth plugins to not appear if they are not configured
He registers locally and think “Ok – Now what??
Confused he goes to the documentation or sees a video
He Gets to the cli section and understand that he needs to add a role to his user.
Opens a terminal and run mean user -a admin myNewUser
When nothing happens he reloads the page and sees himself logged in.
To understand what is installed or to change a theme he needs to browse the mean site or docs – figure out he can extend mean with some packages.
Obviously this is a nightmare! I have a new sense of appreciation to the existing community on how they actually needed to fight against the current to understand why mean is great (beyond assessing the code) – and we need to change this. The change proposed and which I’d like to share is the following
The developer enters localhost:3000
He gets routed to the sign up page with a title that states “Create your first (Administration) user
A user with role admin will be created
The user will be routed to the homepage that will look like this….
Hi Meaningful people! We are working in several ways on improving mean – A lot of stuff is happening around modularising and cleaning up the mean core, providing easier ways to contribute packages and general ongoing fixes. One thing that will surely be apparent is our redesign of the Login/Register and Forgot a password screens. Beyond looking better this is why this is important
Better UX and Design – The login/register is one of the first experiences a developer/client sees when he approaches MEAN for the first time. Tyler Spartan Hollywood is helping out in the UX aspects and wording, we Implemented the design from PixelWrapped and basically it’s an important step forward.
Theme package – Till now we did not have any cust css – everything was based on bootstrap – we added a 5th core package called theme – feel free to create your own themes and modify the way MEAN looks and behaves
Login Logic – The whole idea of seeing 3-4 auth providers when you haven’t configured anything created non neccesary cognitive load – we have added some code checking the your config file and if you have DEFAULT_CLIENT_ID in the clientID of each authprovider it will assume that you did not configure it and that it should not be shown.
On of the coolest tricks I learnt recently (thank Yonatan!) is the ability to overide Tal, Alex and Jen from the community all asked me pretty much the same question yesterday.. How can I disregard the system package layout and roll out my own theme I just tried it out and it’s trivial! So have fun (and send me cool “theme” packages)
To load your own packages server side (node) swig based templates all you need to do is to add the following line to your app.js in your newly scaffolded (mean package $packagename) package. In this example I ran mean package mytheme – and enter my line after the Mytheme.register function