- Update
package.json
, setversion
to a prerelease version, e.g.2.0.0-rc1
,3.1.5-rc4
, ... - Run
npm pack
to create package - Run
npm publish <package>.tgz --tag next
to publish the package under thenext
tag - Run
npm install --save package@next
to install prerelease package
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript | |
Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get the latest from GitHub, public repo: | |
$ npm install username/my-new-project --save-dev | |
# GitHub, private repo: | |
$ npm install git+https://token:[email protected]/username/my-new-project.git#master | |
$ npm install git+ssh://[email protected]/username/my-new-project.git#master | |
# … or from Bitbucket, public repo: | |
$ npm install git+ssh://[email protected]/username/my-new-project.git#master --save-dev | |
# Bitbucket, private repo: | |
$ npm install git+https://username:[email protected]/username/my-new-project.git#master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// <div [innerHTML]="your.value | sanitizeHtml" ></div> | |
import { Pipe, PipeTransform } from '@angular/core'; | |
import { DomSanitizer, SafeHtml } from '@angular/platform-browser'; | |
@Pipe({name: 'sanitizeHtml'}) | |
export class SanitizeHtmlPipe implements PipeTransform { | |
constructor(private _sanitizer:DomSanitizer) { | |
} | |
transform(v:string):SafeHtml { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Pull the latest Node image from Docker | |
FROM node:latest | |
# Copy the current directory contents into the container at /app | |
COPY ./ /app/ | |
# Set the working directory to /app | |
WORKDIR /app | |
# Install Node Modules |
This tutorial uses the "Sample hapi.js REST API" project.
Take a look at: https://github.com/agendor/sample-hapi-rest-api/
##Topics
- Introduction
- Installing Node.js
- Installing MySQL
- Setting-up the project
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//We must add the following to your .bashrc (C:\cygwin\home\user\.bashrc): | |
alias ruby='/cygdrive/c/Ruby21-x64/bin/ruby' | |
alias gem='/cygdrive/c/Ruby21-x64/bin/gem.bat' | |
alias irb='/cygdrive/c/Ruby21-x64/bin/irb.bat' | |
alias compass='/cygdrive/c/Ruby21-x64/bin/compass.bat' | |
alias sass='/cygdrive/c/Ruby21-x64/bin/sass.bat' | |
alias scss='/cygdrive/c/Ruby21-x64/bin/scss.bat' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Matslab Question 5 Bonus | |
// Howard PAnton | |
// | |
(function() { | |
// Add new input option | |
$(".add_button").click(function(){ | |
var value = $(".option_name").val(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Q1. PHP - Complete remove_nonAtoZ() below | |
function remove_nonAtoZ($input) { | |
// example data: $input = "BA'3Ndf$%^A&*(nN)A"; | |
// $output = "BANANA"; | |
// Create RegExpr to remove non capital letters | |
$pattern = "/[A-Z]+/"; | |
// Filter using Preg Match | |
preg_match_all($pattern, $input, $match); |
NewerOlder