$ npm -v
: not foundram Files/nodejs/npm: 3: /mnt/c/Program Files/nodejs/npm:
: not foundram Files/nodejs/npm: 5: /mnt/c/Program Files/nodejs/npm:
/mnt/c/Program Files/nodejs/npm: 6: /mnt/c/Program Files/nodejs/npm: Syntax error: word unexpected (expecting "in")
i have node installed for windows (off the nodejs site).
This file contains hidden or 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
| import React from 'react'; | |
| import 'antd/dist/antd.css'; | |
| import './App.css'; | |
| import { Layout, Menu, Breadcrumb } from 'antd' | |
| const { Header, Content, Footer } = Layout | |
| function App() { | |
| return ( | |
| <div className="App"> | |
| <Layout className="layout"> |
This file contains hidden or 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
| /** | |
| * Simple Node.js script to turn a specific page on a Google Sheet | |
| * into a JSON object for the main purpose of HTML Templating. | |
| * | |
| * @author jonobr1 / http://jonobr1.com | |
| * | |
| */ | |
| var https = require('https'); | |
| var path = require('path'); |
This file contains hidden or 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
| <script> | |
| import BlogSection from "~/components/Sections/BlogSection" | |
| import { getAllPosts } from './plugins/getPosts' | |
| console.log('component: ', getAllPosts) | |
| } | |
| </script> |
This file contains hidden or 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
| # If you come from bash you might have to change your $PATH. | |
| # export PATH=$HOME/bin:/usr/local/bin:$PATH | |
| # Path to your oh-my-zsh installation. | |
| export ZSH="/home/mikael/.oh-my-zsh" | |
| # Set name of the theme to load --- if set to "random", it will | |
| # load a random theme each time oh-my-zsh is loaded, in which case, | |
| # to know which specific one was loaded, run: echo $RANDOM_THEME | |
| # See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes |
This file contains hidden or 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
| nmap <F6> :NERDTreeToggle<CR> |
Today we're going to setup our npm installation to be used without root or sudo rights.
By default, if you install packages globally with npm, npm tries to install them into a system directory (i.e. /usr/local/lib/node_modules). With the next steps, we're going to use your home directory for those files.
First we create a directory in your home directory where all the npm packages will be installed.
$ mkdir ~/.node
This file contains hidden or 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
| const path = require('path'); | |
| const fs = require('fs'); | |
| const webpack = require('webpack'); | |
| const { VueLoaderPlugin } = require('vue-loader'); | |
| const CleanWebpackPlugin = require('clean-webpack-plugin'); | |
| const ExtractTextPlugin = require('extract-text-webpack-plugin'); | |
| const HtmlWebpackPlugin = require('html-webpack-plugin'); | |
| const { NODE_ENV } = process.env; |
This file contains hidden or 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
| { | |
| "version": "0.2.0", | |
| "configurations": [ | |
| { | |
| "type": "browser-preview", | |
| "name": "Browser Preview: Attach", | |
| "request": "attach" | |
| }, | |
| { | |
| "type": "browser-preview", |
This file contains hidden or 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
| #==================== Building Stage ================================================ | |
| # Create the image based on the official Node 8.9.0 image from Dockerhub | |
| FROM node:9 | |
| # Create a directory where our app will be placed. This might not be necessary | |
| RUN mkdir -p /app | |
| # Change directory so that our commands run inside this new directory | |
| WORKDIR /app |