Code Monkey home page Code Monkey logo

vue-music's Introduction

vue-music

vue移动端音乐WebApp

预览:http://htmlpreview.github.io/?https://github.com/ccyinghua/vue-music/blob/master/dist/index.html

运行项目

npm install

npm run dev

构建项目

vue init webpack vue-music

cnpm install
npm run dev

cnpm install stylus stylus-loader --save-dev  // 安装stylus处理css

cnpm install babel-runtime --save  // 对ES语法进行转义 

cnpm install fastclick --save  // 解决移动端一些body点击事件的延迟https://github.com/ftlabs/fastclick

cnpm install babel-polyfill --save-dev  // 对ES6的一些新API转义,补丁

// 02-recommend.md
cnpm install jsonp --save  // jsonp方式抓取数据https://github.com/webmodules/jsonp

cnpm install better-scroll --save // 轮播滚动插件 http://ustbhuangyi.github.io/better-scroll/doc/

cnpm install vue-lazyload --save  // 图片懒加载https://github.com/hilongjw/vue-lazyload

1、安装fastclick之后,main.js入口文件

import fastclick from 'fastclick'
fastclick.attach(document.body);

2、安装babel-polyfill之后,main.js

// 需放在第一行
import 'babel-polyfill'

文件夹列表

| - build
| - config
| - resource      -- Markdown文件所用资源图片(项目中可以不要)
| - src
    | - api             -- 放后端请求类的代码(ajax,json请求等)
    | - base            -- 基本通用组件
      | - slider            -- 轮播组件
    | - common          -- 通用的静态资源
        | - fonts           -- 字体文件
        | - image           -- 图片文件
        | - js              -- js文件
        | - stylus          -- 样式文件
    | - components      -- 组件
        | - m-header        -- header头部组件
        | - rank            -- 排行页面
        | - recommend       -- 推荐页面
        | - search          -- 搜索页面
        | - singer          -- 歌手页面
        | - tab             -- Tab栏组件
    | - router          -- 路由配置文件
    | - store           -- vuex相关文件
    | - App.vue
    | - main.js
| - static   -- 项目所用图片,图标
......

配置修改

1、修改路径配置
// webpack.base.conf.js
alias: {
    '@': resolve('src'),
    'common': resolve('src/common'),
    'components': resolve('src/components'),
    'base': resolve('src/base'),
    'api': resolve('src/api')
}

Markdown说明文件

未完待续......

vue-music's People

Contributors

ccyinghua avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.