Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/apal21/vue.js-vuerouter-multiple-subdomains
A sample Vue template to use single Vue.js application over multiple domains/subdomains.
https://github.com/apal21/vue.js-vuerouter-multiple-subdomains
eslint-airbnb subdomain vue-router vue2 vuejs2
Last synced: 2 months ago
JSON representation
A sample Vue template to use single Vue.js application over multiple domains/subdomains.
- Host: GitHub
- URL: https://github.com/apal21/vue.js-vuerouter-multiple-subdomains
- Owner: apal21
- Created: 2018-07-27T07:27:34.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2021-06-04T20:29:28.000Z (over 3 years ago)
- Last Synced: 2023-04-10T17:26:52.506Z (almost 2 years ago)
- Topics: eslint-airbnb, subdomain, vue-router, vue2, vuejs2
- Language: JavaScript
- Homepage: https://gosink.in/vue-js-how-to-handle-multiple-subdomains-on-a-single-app/
- Size: 926 KB
- Stars: 16
- Watchers: 4
- Forks: 9
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Handle multiple subdomains using VueRouter
> A simple Vue.js project which can handle multiple subdomains in a single app using VueRouter.
## Build Setup
``` bash
# install dependencies
npm install# serve with hot reload at localhost:8080
npm run dev# build for production with minification
npm run build# build for production and view the bundle analyzer report
npm run build --report
```## For Windows Users
* This project uses ESLint - Airbnb, which doesn't support a file in CRLF. It only supports LF.
* To convert this project into LF, you need `Git bash` or some other Linux terminal for Windows.
* Open it and run the following commands:```
$ cd src
$ find ./ -type f -exec dos2unix {} \;
```## How to use
* To use this from subdomains locally you need to configure your hosts.
* For detailed explanation and code refer [this link](https://gosink.in/vue-js-how-to-handle-multiple-subdomains-on-a-single-app/)For detailed explanation on how things work, checkout the [guide](http://vuejs-templates.github.io/webpack/) and [docs for vue-loader](http://vuejs.github.io/vue-loader).