Git Product home page Git Product logo

vitest-vue-demi-pnpm-monorepo's Introduction

Vitest + VueDemi + PNPM Workspace (Monorepo) w/ Turborepo

VueDemi is a library that helps you create components that support both Vue 2 and Vue 3.

Here I show you how to test VueDemi for Vue 2 and Vue 3 using Vitest in a PNPM Workspace (Monorepo) environment configured with Turborepo.

Project Structure

  • packages/my-component: A Component created using VueDemi
  • packages/test-vue-2: Running tests on Vue <=2.6
  • packages/test-vue-3: Running tests on Vue >3.0

Getting Started

git clone https://github.com/Gumball12/vitest-vue-demi-pnpm-monorepo.git
cd vitest-vue-demi-pnpm-monorepo

pnpm install # install all dependencies

pnpm test-v2 # run tests for Vue <=2.6
pnpm test-v3 # run tests for Vue >=3.0
pnpm build # build my-component (Files built on `packages/my-component/dist/` are created)

License

MIT @Gumball12

vitest-vue-demi-pnpm-monorepo's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

vitest-vue-demi-pnpm-monorepo's Issues

Make custom vue plugin

packages > my-component,do it's able to wrap as custom vue plugin?

eg:

import { type App } from vue-demi

const customPlugin = (app: App,  options: Record<string, symbol>) {
   app.component(xxx)
}

when monorepo how to fix Vue2.use() and Vue3.use() it's warning Type not adapterable

Thanks for guide

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.