Giter VIP home page Giter VIP logo

ibwei / vue3-ts-base Goto Github PK

View Code? Open in Web Editor NEW
443.0 10.0 128.0 8.48 MB

一个基于vue3+typescript+ant-design-vue 搭建的基础代码库,有完善的类型系统,帮助快速搭建 vue3 的基础代码架构。

Home Page: https://ibwei.github.io/vue3-ts-base/

License: MIT License

JavaScript 6.24% HTML 0.66% TypeScript 89.97% Less 2.94% Dockerfile 0.05% Shell 0.13%
vue3 vue3-demo vue3-typescript vue3-ant vue3-tsx vue ant

vue3-ts-base's People

Contributors

cnmathon avatar ibwei avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vue3-ts-base's Issues

git commit error

at master branch:
when you modify src/styles/normalize.css,then you commit will meet Parsing error: ';' expected at XXX error

[Help] About Vuex modules with typescript

First of all, this is a amazing project which help me a lot.

But I have some trouble with Vuex in Typescript.

This is my // store/about.ts :

// store/about.ts
import modules from './about'
import { StateType } from '@typing/index'
import { Module } from 'vuex'

type AboutStateType = typeof state

const state = {
	aboutInfo: 'info from about state model'
}
const getters = {}
const mutations = {}
const actions = {}

const about: Module<AboutStateType, StateType> = {
	namespaced: true,
	state,
	getters,
	mutations,
	actions
	modules  // Here,Typescript have warning: 不能将类型“Module<{ aboutInfo: string; }, VuexModuleType>”分配给类型“ModuleTree<VuexModuleType>”。
}
export { AboutStateType, state }
export default about

And my project directory like this:

截屏2021-01-12 16 57 11

In the above example, There are other modules under the about module.
But TypeScript Can not Identify the type correctly.
I tried to solve this problem, but still don’t know what to do. Can you provide some help for this ?
Thanks a lot!

请教下大佬,如何全局注册并使用 message组件

vue2.0是通过 把message挂载到vue原型,vue3.0在setup中怎么使用message组件,按项目的配置,还是不能使用

  1. config.js 引入 message组件并添加到 AppConfig对象上
    2.在main.ts中配置app.config.globalProperties = AppConfig
    3.跟目录下创建global.d.ts
    4.在组件中,setup中使用报错,不能在setup中使用this

📣📣📣【DEVELOPER MUST READ | 开发者必读】Project Maintenance Migration Notice | 项目维护迁移公告

IMPORTANCE NOTICE

After consultation with the original owner of this project, due to the busy schedule of the original owner of this project, there will be no more energy to maintain this project subsequently. Therefore, for the long-term development of the project, the subsequent maintenance of this project is now relocated to the new repository for this project. We hereby inform you.

New Repository Link

VuePlusOrg/vue3-base

重要告知

经本项目原所有者协商,因本项目原所有者工作繁忙的原因,后续将没有更多的精力维护此项目。因此,为了项目的长期发展,现将本项目后续维护迁移至新仓库进行。特此告知。

新仓库地址

VuePlusOrg/vue3-base

how to dispatch actions

in a.vue page
eg :how to dispatch actions

created(){
   this.$store.dispatch('refreshToken') //unknown action type: refreshToken
}

Vite

考虑使用 vite 吗

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.