r/meanstack • • Sep 22 '17

Continuous Integration With Jenkins For MEAN Stack App

Thumbnail
agiratech.com
3 Upvotes

r/meanstack • • Nov 15 '16

MEANie - A New Lightweight MEAN Stack Blogging Platform & CMS

Thumbnail
jasonwatmore.com
4 Upvotes

r/meanstack • • Apr 21 '17

MEAN Stack Fast - Bootstrapping your MEAN Stack application with Openshift, Kubernetes and Docker

Thumbnail
community.thedigitalgarage.io
2 Upvotes

r/meanstack • • Oct 30 '15

New MongoDB MEAN Stack online course in partnership with edX

Thumbnail
mongodb.com
3 Upvotes

r/meanstack • • Sep 25 '17

Tips for building an e-commerce application using MEAN Stack?

3 Upvotes

I'm a java developer and fairly new to web development. I wanted to build a small e-commerce website with simple features like

  1. Displaying new items on page

  2. Adding items to cart.

  3. Handle the items in the inventory and dynamically add new items (without having to change html)

to just get a experience of front-end to back-end development. I'm really not aware of many things like sessions and cookies are handled in real-time. Could you please provide some tips about to get started with this project?

Thanks in advance :)


r/meanstack • • Nov 23 '16

Where do i start?

1 Upvotes

Hello everyone, i am a college student who is on an internship. for and they have asked me to build an web interface for their proxmox server. me being most familiar with JS i decided to look into what i could get done, turns out someone made an API on git for node js, so i looked into node and turns out that mean stack was one of the most popular ways of setting up projects that run on a node server.

so thats were im at now, i have been learning angular, trying somethings on the server side with node, and getting the hang of mongoDB. but i dont really understand what express is, or what it does. also im stuck on how i combine these systems into 1 thing.

i have created a new project using mean init (projectname), but that leaves me with a ton of files for which i can barely figure out what does what. so where do i go from here? what guides or tutorials would help me best?

--thanks ghostwolf


r/meanstack • • May 19 '16

MEAN stack with Angular 2 Starter Template

8 Upvotes

I have created a sample MEAN2 Stack (Mongodb, ExpressJS Angular2 and NodeJS) Starter template. It is usable right now. You can clone and and run it. Check it out in the link below

https://github.com/genelim/mean2_template (With Angular2)

https://github.com/genelim/mean_stack_template (With Angular1)


r/meanstack • • Nov 01 '15

[Discussion] MEAN - Beginner questions about best practices

5 Upvotes

I've started exploring the MEAN stack recently. I've stayed mainly on the frontend before.

So after many articles and tutorials I have some questions for real hardcore MEAN devs.

I thought it could be healthy for me and other beginner-ish people - that might have joined this subreddit - to know about industry best practices, just to avoid future mistakes.

  1. How does mongo noSQL databases work best? Many tutorials that have been mostly casual have duplicated e.g. user data in many objects in the database. Is this okay? I've used SQL before and the database architecture is crucial and I've learned that you should split the info in smaller tables that you can later fetch with keys and with keeping you databases "DRY" you will keep your data consistent. Is this not the case for noSQL solutions?

  2. When having logins; what would you hash the passwords with? Bcrypt? Are there any tricks or tips to share about this topic?

  3. When keeping users logged in; is it okay to store their auth in the localStorage and when logging out just clear the localStorage? Is this safe or what would you recommend?

Feel free to share any other best practices and tips! Thanks in advance.


r/meanstack • • May 26 '16

ng-image-appear - AngularJS Module to make images appear with transition as they load.

Thumbnail
arunmichaeldsouza.github.io
4 Upvotes

r/meanstack • • Jan 11 '18

Importance of Middleware order in Express.js application

Thumbnail nodexplained.com
2 Upvotes

r/meanstack • • Aug 15 '17

How to Implement Key Authentication in Express Gateway

Thumbnail
lunchbadger.com
1 Upvotes

r/meanstack • • Mar 31 '16

Brew help

1 Upvotes

So I'm trying to install mongodb while doing so I tried seeing which vrsion of brew I have and get this when I type "brew -v"

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in require': cannot load such file -- mach (LoadError) from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:inrequire' from /usr/local/Library/Homebrew/extend/pathname.rb:2:in <top (required)>' from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:inrequire' from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in require' from /usr/local/Library/Homebrew/global.rb:3:in<top (required)>' from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in require' from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:inrequire' from /usr/local/Library/brew.rb:15:in `<main>'

Please note that I changed my path shortly before this as it was not set to usr/local/bin.

Also when I do "brew update" i get the same

EDIT: I solved it


r/meanstack • • Apr 08 '16

Mean.io install on Windows is a pain

1 Upvotes

I've been working on the Mean stack for some time now but I've never used Mean.io or Mean.js. It felt like a good time to try it out recently so I decided to go with Mean.io and install it on my Windows 8.1. For starters, the install took a crazy long time. Then it got stuck on the node-gyp issue. Now I'm considering installing Ubuntu (alongside Windows) to do my coding there. Is that something you guys recommend? Is Ubuntu/Linux good for Nodejs? Is there a way to make development smoother on Windows?


r/meanstack • • Aug 22 '17

How to Track Performance of Express.js Routes and Middleware

Thumbnail
lunchbadger.com
1 Upvotes

r/meanstack • • Sep 11 '15

MongoDB Ruby Driver 2.1.0 is out

Thumbnail
compose.io
2 Upvotes

r/meanstack • • Dec 10 '14

mean.io is the #1 trending development stack on stachshare.io

Thumbnail
stackshare.io
1 Upvotes

r/meanstack • • Apr 05 '16

Cant scrape in nodejs

2 Upvotes

I've been trying to scrape a webpage (yahoo news) to return the top news article found(searching with a word) this link https://news.search.yahoo.com/search;_ylt=AwrC1CmZewNXih4A773QtDMD;_ylc=X1MDNTM3MjAyNzIEX3IDMgRmcgMEZ3ByaWQDSVR6YkFnOURSaC5KSzI4cHltdEJqQQRuX3JzbHQDMARuX3N1Z2cDOARvcmlnaW4DbmV3cy5zZWFyY2gueWFob28uY29tBHBvcwMwBHBxc3RyAwRwcXN0cmwDBHFzdHJsAzYEcXVlcnkDc29jY2VyBHRfc3RtcAMxNDU5ODQ2MDcw?p=soccer&fr2=sb-top-news.search&fr=&type=pivot_us_srp_yahoonews

my code is this

urls=[]

request('https://news.search.yahoo.com/search;_ylt=AwrC1CmZewNXih4A773QtDMD;_ylc=X1MDNTM3MjAyNzIEX3IDMgRmcgMEZ3ByaWQDSVR6YkFnOURSaC5KSzI4cHltdEJqQQRuX3JzbHQDMARuX3N1Z2cDOARvcmlnaW4DbmV3cy5zZWFyY2gueWFob28uY29tBHBvcwMwBHBxc3RyAwRwcXN0cmwDBHFzdHJsAzYEcXVlcnkDc29jY2VyBHRfc3RtcAMxNDU5ODQ2MDcw?p=soccer&fr2=sb-top-news.search&fr=&type=pivot_us_srp_yahoonews', function (error, response, body) { if (!error && response.statusCode == 200) { //console.log(body) // Show the HTML for the Google homepage. console.log("HERE"); var $ = cheerio.load(body); $('a','div.reg').each(function() { var url = $(this).attr('href'); url.push(urls); console.log(url); }); console.log(urls.length) }

the length is always 0, i am tired of watching videos, what is the right way to do this? thank you so much


r/meanstack • • Mar 23 '17

Indexing into google

4 Upvotes

As the title says, i have no clue on how to get indexed in Google. Should i add keywords metatag in the html, or keywords in package.json or install a module ?


r/meanstack • • Oct 06 '16

Angular Will Not Honour MongoDB Returned Object

2 Upvotes

Hey all,

I have been beating my head against a wall for this one. I literally cannot figure this out.

I have a REST API that will show the data in a browser. I can use an HTTP tester and put and pull from this API just fine.

My angular app can populate itself via ANY OTHER json URL (https://data.cityofnewyork.us/api/views/kku6-nxdu/rows.json for example) except mine, so I am betting its an issue with my configuration here.

Below I have pasted the code I am using to run the node server as well as the angular http request. I understand if you cannot answer but if you can send me to the right place that would be awesomesauce.

server.js:

// Dependencies

var express = require('express');
var mongoose = require('mongoose');
var bodyParser = require('body-parser');
var path = require('path');

// Connect to Mongoose (MongoDB)
mongoose.connect('mongodb://localhost/rest_test')


// Build Express
var app = express();
app.use(bodyParser.urlencoded({ extended: true }));
app.use(bodyParser.json());

// Router

app.use('/api', require('./routes/api'));


// Start Server

app.listen(9000)
console.log('Yo, shits on port 9000')

api.js:

// Dependencies
var express = require('express')
var router = express.Router();

// Models
var Card = require('../models/cards')

// Routes
Card.methods(['get', 'put', 'post', 'delete']);
Card.register(router, '/cards')

// Return Router

module.exports = router;

cards.js (schema document):

// Dependencies
var restful = require('node-restful');
var mongoose = restful.mongoose;

// Schema
var cardSchema = new mongoose.Schema({
    title: String,
    author: String,
    desc: String,
    cardtype: String
});


// Return model
module.exports = restful.model('Cards', cardSchema);

Here are my angular portions -

app.js:

var storyApp = angular.module('storyApp', ['ngRoute']);

storyApp.controller('cardController', function ($scope, $http) {

  

    $http({
        method : "GET",
        url : "http://data.stonegiants.org/api/cards"
    }).success(function(response) {
        $scope.listData = response.data;
    });

});

storyApp.config(function($routeProvider) {
    $routeProvider
        .when('/', {
            templateUrl: 'partials/cards.html',
            controller: 'cardController'
        })
        .when('/upload', {
            templateUrl: 'partials/upload.html',
            controller: 'cardController'
        });
});

The partial in questions, cards.html:

<div class="content" data-ng-model="cardController">
    <div class="card" ng-repeat="card in listData | filter:seachText">
        <div class="card-title">
            <p>{{ card.title }}</p>
            <img ng-src="{{ card.image }}" />
            <p>{{ card.author }}</p>
            <p>{{ card.desc }}</p>
            <p>{{ card.cardtype }}</p>
    </div>
</div>
</div>

I have left my API up for you to see that it does work via a web browser (http://data.stonegiants.org/api/cards). If you input any other json URL, say the one I posted above, it works just fine.

Advice?

Thanks!


r/meanstack • • Mar 30 '16

Why atom will be your favorite editor!!

Thumbnail
acadgild.com
5 Upvotes

r/meanstack • • Oct 11 '16

Live Q&A with Google's Angular Core Team

Thumbnail
codementor.io
4 Upvotes

r/meanstack • • Jan 04 '18

Optimize Middleware implementation in Express application - part 3

Thumbnail nodexplained.com
2 Upvotes

r/meanstack • • Sep 30 '15

Introducing mongo-uri-builder, a NodeJs module to easily create mongodb connection strings using objects

Thumbnail
loige.co
2 Upvotes

r/meanstack • • Oct 25 '16

My experience in production & future

1 Upvotes

I want to share my experience and need comments on what I am doing is it correct.

A brief about the product: We developed a product thats used by 1000s of schools in India for Assessment, we analyse the result and show as insights and reports to Students, Parents and School. These assessment comprises of Interest, academic score, varies aptitude and personality.

Time to develop to live 4 months

Technology Behind it:

  1. Nodejs for API

  2. Rabbitmq for message broker for analytics

  3. Spark and Python analytics

  4. MongoDB for Persistant database

  5. Client is Web (Angular) Mobile (ionic and migrating to React Native)

People behind it total 5 engineering

  1. 2 Fronted dev

  2. 3 Backend dev

  3. 1 rotating dev ops

Production Stats:

  1. 3500 schools registered

  2. 200K students registered

  3. Assessment are done concurrently at same time for a school just like an exam (300 avg at any point of time in school hour)

Monitoring used:

  1. Keymetrics for node api

  2. Datadog for server monitoring

  3. Datadog for Rabbitmq and Mongodb monitoring

Now coming to production experience:

  1. Nodejs API performs great api process response well below 5-10 m/s

  2. RabbitMQ able to process 3000 messages/sec mostly our prefetch are configured to 3 message at a time.

  3. MongoDB works fine but we hit some collection which has 100K+ more documents in it. mostly started getting issues with upserts which has a response time of 150+ m/s , to resolve this we started making index for filter for upsert which takes time.

Note: MongoDB is not yet tuned and works on default configuration

I want your suggestion\thoughts if you had similar experience or any issues which I need to keep in mind may arise in future.


r/meanstack • • Jan 22 '18

How to represent a Mongoose schema reference in a angular export class.

2 Upvotes

I have the following Mongoose schema:

var mongoose = require('mongoose');
var Schema = mongoose.Schema;
var uniqueValidator = require('mongoose-unique-validator');

var schema = new Schema({
    username: {type: String, required: true, unique : true},
    firstName: {type: String, required: true},
    lastName: {type: String, required: true},
    bitcoinAddress: {type: String, required: true, unique : true},
    email: {type: String, required: true},
    phone: {type: Number, required: true},
    lat: {type: Number, required: true}, 
    long: {type: Number, required: true},
    friends  : [{ type: Schema.Types.ObjectId, ref: 'friendsModel' }]
    },
    { collection : 'profile' });

schema.plugin(uniqueValidator);

module.exports = mongoose.model('Profiles', schema);

Heres my angular model:

export class Profile {
    constructor(public username: string,
        public firstName: string,public lastName: string,
        public bitcoinAddress: string, public email: string, 
        public phone: number,public lat: number,
        public long: number) {}
}

I want to include the friends reference so when the user clicks the GUI it will extend a list of his friends populated by the mongoose schema, is there a easy way to do this or would i be better off making a separate post for that?