repo
stringlengths
5
106
file_url
stringlengths
78
301
file_path
stringlengths
4
211
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 14:56:49
2026-01-05 02:23:25
truncated
bool
2 classes
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/todomvc/store/index.js
examples/composition/todomvc/store/index.js
import { createStore } from 'vuex' import { mutations, STORAGE_KEY } from './mutations' import actions from './actions' import plugins from './plugins' export default createStore({ state: { todos: JSON.parse(window.localStorage.getItem(STORAGE_KEY) || '[]') }, actions, mutations, plugins })
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/todomvc/store/mutations.js
examples/composition/todomvc/store/mutations.js
export const STORAGE_KEY = 'todos-vuejs' // for testing if (navigator.webdriver) { window.localStorage.clear() } export const mutations = { addTodo (state, todo) { state.todos.push(todo) }, removeTodo (state, todo) { state.todos.splice(state.todos.indexOf(todo), 1) }, editTodo (state, { todo, te...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/todomvc/store/actions.js
examples/composition/todomvc/store/actions.js
export default { addTodo ({ commit }, text) { commit('addTodo', { text, done: false }) }, removeTodo ({ commit }, todo) { commit('removeTodo', todo) }, toggleTodo ({ commit }, todo) { commit('editTodo', { todo, done: !todo.done }) }, editTodo ({ commit }, { todo, value }) { ...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter-hot/app.js
examples/composition/counter-hot/app.js
import { createApp } from 'vue' import store from './store' import CounterControls from './CounterControls.vue' const app = createApp(CounterControls) app.use(store) app.mount('#app')
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter-hot/store/getters.js
examples/composition/counter-hot/store/getters.js
export const count = state => state.count export const t = (state) => { return state.test } const limit = 5 export const recentHistory = state => { const end = state.history.length const begin = end - limit < 0 ? 0 : end - limit return state.history .slice(begin, end) .join(', ') }
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter-hot/store/index.js
examples/composition/counter-hot/store/index.js
import { createStore } from 'vuex' import * as getters from './getters' import * as actions from './actions' import * as mutations from './mutations' const state = { test: 0, count: 0, history: [] } const store = createStore({ state, getters, actions, mutations }) if (module.hot) { module.hot.accept(...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter-hot/store/mutations.js
examples/composition/counter-hot/store/mutations.js
export const increment = state => { state.count++ state.history.push('increment') } export const decrement = state => { state.count-- state.history.push('decrement') }
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter-hot/store/actions.js
examples/composition/counter-hot/store/actions.js
export const increment = ({ commit }) => { commit('increment') } export const decrement = ({ commit }) => { commit('decrement') } export const incrementIfOdd = ({ commit, state }) => { if ((state.count + 1) % 2 === 0) { commit('increment') } } export const incrementAsync = ({ commit }) => { setTimeout((...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter/app.js
examples/composition/counter/app.js
import { createApp } from 'vue' import Counter from './Counter.vue' import store from './store' const app = createApp(Counter) app.use(store) app.mount('#app')
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/counter/store.js
examples/composition/counter/store.js
import { createStore } from 'vuex' // root state object. // each Vuex instance is just a single state tree. const state = { count: 0 } // mutations are operations that actually mutate the state. // each mutation handler gets the entire state tree as the // first argument, followed by additional payload arguments. /...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/shopping-cart/app.js
examples/composition/shopping-cart/app.js
import { createApp } from 'vue' import App from './components/App.vue' import store from './store' const app = createApp(App) app.use(store) app.mount('#app')
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/shopping-cart/currency.js
examples/composition/shopping-cart/currency.js
const digitsRE = /(\d{3})(?=\d)/g export function currency (value, currency, decimals) { value = parseFloat(value) if (!isFinite(value) || (!value && value !== 0)) return '' currency = currency != null ? currency : '$' decimals = decimals != null ? decimals : 2 var stringified = Math.abs(value).toFixed(decim...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/shopping-cart/store/index.js
examples/composition/shopping-cart/store/index.js
import { createStore, createLogger } from 'vuex' import cart from './modules/cart' import products from './modules/products' const debug = process.env.NODE_ENV !== 'production' export default createStore({ modules: { cart, products }, strict: debug, plugins: debug ? [createLogger()] : [] })
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/shopping-cart/store/modules/products.js
examples/composition/shopping-cart/store/modules/products.js
import shop from '../../api/shop' // initial state const state = { all: [] } // getters const getters = {} // actions const actions = { getAllProducts ({ commit }) { shop.getProducts(products => { commit('setProducts', products) }) } } // mutations const mutations = { setProducts (state, produ...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/shopping-cart/store/modules/cart.js
examples/composition/shopping-cart/store/modules/cart.js
import shop from '../../api/shop' // initial state // shape: [{ id, quantity }] const state = { items: [], checkoutStatus: null } // getters const getters = { cartProducts: (state, getters, rootState) => { return state.items.map(({ id, quantity }) => { const product = rootState.products.all.find(produ...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vuex
https://github.com/vuejs/vuex/blob/bd907467b8392d6671bb115738285ff7f63d0cf6/examples/composition/shopping-cart/api/shop.js
examples/composition/shopping-cart/api/shop.js
/** * Mocking client-server processing */ const _products = [ { 'id': 1, 'title': 'iPad 4 Mini', 'price': 500.01, 'inventory': 2 }, { 'id': 2, 'title': 'H&M T-Shirt White', 'price': 10.99, 'inventory': 10 }, { 'id': 3, 'title': 'Charli XCX - Sucker CD', 'price': 19.99, 'inventory': 5 } ] export default { get...
javascript
MIT
bd907467b8392d6671bb115738285ff7f63d0cf6
2026-01-04T15:02:06.558064Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/.eslintrc.js
.eslintrc.js
module.exports = { extends: [ '@vue/standard' ], globals: { name: 'off' }, rules: { indent: ['error', 2, { MemberExpression: 'off' }], quotes: [2, 'single', { avoidEscape: true, allowTemplateLiterals: true }], 'quote-props': 'off', 'no-shadow': ['error'], 'node/no-extrane...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/jest.config.js
jest.config.js
module.exports = { 'testEnvironment': 'node', 'setupFiles': [ '<rootDir>/scripts/testSetup.js' ], 'testMatch': [ '**/__tests__/**/*.spec.js' ] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/genChangelog.js
scripts/genChangelog.js
const fs = require('fs') const path = require('path') const execa = require('execa') async function genNewRelease () { if (process.env.GIT_E2E_SETUP) { return 'skipped for e2e testing' } const nextVersion = require('../lerna.json').version const { stdout } = await execa(require.resolve('lerna-changelog/bi...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/verifyCommitMsg.js
scripts/verifyCommitMsg.js
const chalk = require('chalk') // eslint-disable-line const msgPath = process.env.GIT_PARAMS const msg = require('fs').readFileSync(msgPath, 'utf-8').trim() const commitRE = /^(v\d+\.\d+\.\d+(-(alpha|beta|rc.\d+))?)|((revert: )?(feat|fix|docs|style|refactor|perf|test|workflow|ci|chore|types)(\(.+\))?!?: .{1,50})/ if...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/syncDeps.js
scripts/syncDeps.js
/* eslint-disable */ // make sure generators are using the latest version of plugins, // and plugins are using the latest version of deps const fs = require('fs') const path = require('path') const chalk = require('chalk') const fetch = require('node-fetch') const semver = require('semver') const globby = require('glo...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/release.js
scripts/release.js
/** How to do a release: 1. Make sure you have publish access for all packages: - You must be in the CLI team in the npm @vue organization - You must have publish access to vue-cli-version-marker - Make sure you DO NOT have npm per-publish 2-factor / OTP enabled, as it does not work with Lerna (whic...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/test.js
scripts/test.js
const minimist = require('minimist') const rawArgs = process.argv.slice(2) const args = minimist(rawArgs) let regex if (args.p) { const packages = (args.p || args.package).split(',').join('|') regex = `.*@vue/(${packages}|cli-plugin-(${packages}))/.*\\.spec\\.js$` const i = rawArgs.indexOf('-p') rawArgs.splice...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/checkLinks.js
scripts/checkLinks.js
require('events').defaultMaxListeners = 0 const path = require('path') const fs = require('fs') const fetch = require('node-fetch') const promises = [] async function checkLink (file, link, n) { try { const result = await fetch(link, { method: 'HEAD' }) if (result.status !== 200) { throw new Error('er...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/bootstrap.js
scripts/bootstrap.js
// create package.json and README for packages that don't have one yet const fs = require('fs') const path = require('path') const baseVersion = require('../packages/@vue/cli-service/package.json').version const packagesDir = path.resolve(__dirname, '../packages/@vue') const files = fs.readdirSync(packagesDir) files...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/buildEditorConfig.js
scripts/buildEditorConfig.js
// Generate editorconfig templates from built-in eslint configs. // Supported rules: // indent_style // indent_size // end_of_line // trim_trailing_whitespace // insert_final_newline // max_line_length const fs = require('fs') const path = require('path') const ESLint = require('eslint').ESLint // Convert eslint rul...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/patchChromedriver.js
scripts/patchChromedriver.js
// Appveyor current only ships Chrome 72 // which is no longer supported by the latest version of Chromedriver. const fs = require('fs') const path = require('path') const pkg = require('../package.json') const versionString = require('child_process').execSync('wmic datafile where name="C:\\\\Program Files (x86)\\\\G...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/genDocs.js
scripts/genDocs.js
const fs = require('fs') const path = require('path') const pluginsDirPath = path.resolve(__dirname, '../packages', '@vue') const pluginRegEx = new RegExp('cli-plugin-') function generatePluginDoc (plugin) { const entryPath = path.resolve(__dirname, '../packages', '@vue', plugin, 'README.md') const entryContent =...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/scripts/testSetup.js
scripts/testSetup.js
process.env.VUE_CLI_TEST = true process.env.VUE_CLI_SKIP_DIRTY_GIT_PROMPT = true
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/docs/.vitepress/config.js
docs/.vitepress/config.js
const fs = require('fs') const path = require('path') const selfDestroyingSWVitePlugin = { name: 'generate-self-destroying-service-worker', buildStart() { this.emitFile({ type: 'asset', fileName: 'service-worker.js', source: fs.readFileSync(path.join(__dirname, './self-destroying-service-work...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/docs/.vitepress/self-destroying-service-worker.js
docs/.vitepress/self-destroying-service-worker.js
// https://github.com/NekR/self-destroying-sw /** * The MIT License (MIT) * * Copyright (c) 2017 Arthur Stolyar <nekr.fabula@gmail.com> * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Softwa...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/docs/.vitepress/theme/index.js
docs/.vitepress/theme/index.js
import { h } from 'vue' import DefaultTheme from 'vitepress/dist/client/theme-default' import AlgoliaSearchBox from './AlgoliaSearchBox.vue' import './custom.css' import { useData } from 'vitepress' export default { ...DefaultTheme, Layout: { setup() { const { lang } = useData() return () => { ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/.eslintrc.js
packages/@vue/cli-ui-addon-webpack/.eslintrc.js
module.exports = { root: true, extends: [ 'plugin:vue/essential', '@vue/standard' ], globals: { ClientAddonApi: false, mapSharedData: false, Vue: false, name: 'off' }, parserOptions: { parser: '@babel/eslint-parser', babelOptions: { cwd: __dirname } }, rules: { ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/babel.config.js
packages/@vue/cli-ui-addon-webpack/babel.config.js
module.exports = { presets: ['@vue/cli-plugin-babel/preset'] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/vue.config.js
packages/@vue/cli-ui-addon-webpack/vue.config.js
const { clientAddonConfig } = require('@vue/cli-ui') module.exports = { ...clientAddonConfig({ id: 'org.vue.webpack.client-addon', port: 8096 }) }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/src/main.js
packages/@vue/cli-ui-addon-webpack/src/main.js
import VueProgress from 'vue-progress-path' import WebpackDashboard from './components/WebpackDashboard.vue' import WebpackAnalyzer from './components/WebpackAnalyzer.vue' import TestView from './components/TestView.vue' Vue.use(VueProgress, { defaultShape: 'circle' }) /* eslint-disable vue/multi-word-component-nam...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/src/filters.js
packages/@vue/cli-ui-addon-webpack/src/filters.js
export function size (size, unit = '', precision = 1) { const kb = { label: 'k', value: 1024 } const mb = { label: 'M', value: 1024 * 1024 } let denominator if (size >= mb.value) { denominator = mb } else { denominator = kb if (size < kb.value * 0.92 && precision === 0) { ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/src/util/assets.js
packages/@vue/cli-ui-addon-webpack/src/util/assets.js
import speedsData from '../assets/speeds.json' const DOWNLOAD_TIME_THRESHOLD_SECONDS = 5 export function getSpeedData (datapoint, size) { const assetsSizeInMB = size / 1024 / 1024 const bandwidthInMbps = datapoint.mbps const bandwidthInMBps = bandwidthInMbps / 8 const rttInSeconds = datapoint.rtt / 1000 co...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/src/util/colors.js
packages/@vue/cli-ui-addon-webpack/src/util/colors.js
export default { light: [ [ '#42b983', '#5DC395', '#78CDA7', '#93D7B9', '#AEE1CB', '#C9EBDD' ], [ '#A96FDA', '#B684DF', '#C399E4', '#D0AEE9', '#DDC3EE', '#EAD8F3' ], [ '#03C2E6', '#27CBEA', '#4BD4EE', '...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/src/store/index.js
packages/@vue/cli-ui-addon-webpack/src/store/index.js
import Vuex from 'vuex' import { buildSortedAssets } from '../util/assets' Vue.use(Vuex) const store = new Vuex.Store({ state () { return { sizeField: localStorage.getItem('org.vue.vue-webpack.sizeField') || 'parsed', mode: 'serve', showModernBuild: true, serve: { stats: null, ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-ui-addon-webpack/src/mixins/Dashboard.js
packages/@vue/cli-ui-addon-webpack/src/mixins/Dashboard.js
import store from '../store' // @vue/component export default { store, inject: [ 'TaskDetails' ], data () { return { mode: null } }, sharedData () { return { serveUrl: 'org.vue.webpack.serve-url', modernMode: 'org.vue.webpack.modern-mode' } }, computed: { s...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/index.js
packages/@vue/cli-plugin-e2e-nightwatch/index.js
const fs = require('fs') const { installedBrowsers, info, warn, error, chalk, execa } = require('@vue/cli-shared-utils') module.exports = (api, options) => { api.registerCommand('test:e2e', { description: 'run end-to-end tests with nightwatch', usage: 'vue-cli-service test:e2e [options]', options: { ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/prompts.js
packages/@vue/cli-plugin-e2e-nightwatch/prompts.js
const { installedBrowsers } = require('@vue/cli-shared-utils') module.exports = [ { name: 'webdrivers', type: `checkbox`, message: `Pick browsers to run end-to-end test on`, choices: [ { name: `Chrome`, value: 'chrome', checked: true }, { name: 'Firef...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/ui.js
packages/@vue/cli-plugin-e2e-nightwatch/ui.js
module.exports = api => { api.describeTask({ match: /vue-cli-service test:e2e/, description: 'org.vue.nightwatch.tasks.test.description', link: 'https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-e2e-nightwatch#injected-commands', prompts: [ { name: 'url', type:...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/nightwatch.conf.js
packages/@vue/cli-plugin-e2e-nightwatch/nightwatch.conf.js
// Autogenerated by Nightwatch // Refer to the online docs for more details: https://nightwatchjs.org/gettingstarted/configuration/ const path = require('path') const deepmerge = require('deepmerge') const Services = {} loadServices() const VUE_DEV_SERVER_URL = process.env.VUE_DEV_SERVER_URL const BROWSERSTACK_USER =...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/index.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/index.js
const { installedBrowsers } = require('@vue/cli-shared-utils') module.exports = (api, { webdrivers }) => { api.render('./template', { hasTS: api.hasPlugin('typescript'), hasESLint: api.hasPlugin('eslint') }) const devDependencies = {} // Use devDependencies to store latest version number so as to aut...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/_eslintrc.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/_eslintrc.js
<%_ if (hasESLint) { _%> module.exports = { rules: { <%_ if (hasTS) { _%> '@typescript-eslint/no-var-requires': 'off', <%_ } _%> 'no-unused-expressions': 'off' } } <%_ } _%>
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/globals.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/globals.js
/////////////////////////////////////////////////////////////////////////////////// // Refer to the entire list of global config settings here: // https://github.com/nightwatchjs/nightwatch/blob/master/lib/settings/defaults.js#L16 // // More info on test globals: // https://nightwatchjs.org/gettingstarted/configurati...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-assertions/elementCount.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-assertions/elementCount.js
/** * A custom Nightwatch assertion. The assertion name is the filename. * * Example usage: * browser.assert.elementCount(selector, count) * * For more information on custom assertions see: * https://nightwatchjs.org/guide/extending-nightwatch/#writing-custom-assertions * * * @param {string|object} select...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/page-objects/homepage.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/page-objects/homepage.js
/** * A Nightwatch page object. The page object name is the filename. * * Example usage: * browser.page.homepage.navigate() * * For more information on working with page objects see: * https://nightwatchjs.org/guide/working-with-page-objects/ * */ module.exports = { url: '/', commands: [], // A pag...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/specs/test-with-pageobjects.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/specs/test-with-pageobjects.js
//////////////////////////////////////////////////////////////// // For authoring Nightwatch tests, see // https://nightwatchjs.org/guide // // For more information on working with page objects see: // https://nightwatchjs.org/guide/working-with-page-objects/ //////////////////////////////////////////////////////////...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/specs/test.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/specs/test.js
// For authoring Nightwatch tests, see // https://nightwatchjs.org/guide module.exports = { 'default e2e tests': browser => { browser .init() .waitForElementVisible('#app') .assert.elementPresent('.hello') .assert.containsText('h1', 'Welcome to Your Vue.js <%- hasTS ? '+ TypeScript ' : ''...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-commands/openHomepage.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-commands/openHomepage.js
/** * A basic Nightwatch custom command * which demonstrates usage of ES6 async/await instead of using callbacks. * The command name is the filename and the exported "command" function is the command. * * Example usage: * browser.openHomepage(); * * For more information on writing custom commands see: * ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-commands/openHomepageClass.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-commands/openHomepageClass.js
/** * A class-based Nightwatch custom command which is a variation of the openHomepage.js command. * The command name is the filename and class needs to contain a "command" method. * * Example usage: * browser.openHomepageClass(); * * For more information on writing custom commands see: * https://nightwatc...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-commands/customExecute.js
packages/@vue/cli-plugin-e2e-nightwatch/generator/template/tests/e2e/custom-commands/customExecute.js
/** * A very basic Nightwatch custom command. The command name is the filename and the * exported "command" function is the command. * * Example usage: * browser.customExecute(function() { * console.log('Hello from the browser window') * }); * * For more information on writing custom commands see: * ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/__tests__/nightwatchPlugin.spec.js
packages/@vue/cli-plugin-e2e-nightwatch/__tests__/nightwatchPlugin.spec.js
jest.setTimeout(process.env.APPVEYOR ? 300000 : 120000) const fs = require('fs-extra') const path = require('path') const create = require('@vue/cli-test-utils/createTestProject') const createServer = require('@vue/cli-test-utils/createServer') describe('nightwatch e2e plugin', () => { let project beforeAll(asyn...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/__tests__/lib/globals-gecko.js
packages/@vue/cli-plugin-e2e-nightwatch/__tests__/lib/globals-gecko.js
/** * This file is copied during the firefox test inside the project folder and used to inspect the results */ const fs = require('fs') module.exports = { reporter (results, cb) { fs.writeFile('test_results_gecko.json', JSON.stringify(results), cb) } }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/__tests__/lib/globals-generated.js
packages/@vue/cli-plugin-e2e-nightwatch/__tests__/lib/globals-generated.js
/** * This file is copied during the test inside the project folder and used to inspect the results */ const fs = require('fs') module.exports = { afterEach (browser, cb) { fs.writeFile('test_settings.json', JSON.stringify(browser.options), cb) }, reporter (results, cb) { fs.writeFile('test_results.js...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-nightwatch/__tests__/lib/nightwatch.conf.js
packages/@vue/cli-plugin-e2e-nightwatch/__tests__/lib/nightwatch.conf.js
/** * This file is copied during the test inside the project folder */ module.exports = { globals_path: './tests/e2e/globals-gecko.js' }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/setup.js
packages/@vue/cli-plugin-unit-mocha/setup.js
require('jsdom-global')(undefined, { pretendToBeVisual: true, url: 'http://localhost' }) // https://github.com/vuejs/vue-test-utils/issues/936 window.Date = Date // https://github.com/vuejs/vue-next/pull/2943 global.ShadowRoot = window.ShadowRoot global.SVGElement = window.SVGElement // https://github.com/vuejs/test...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/index.js
packages/@vue/cli-plugin-unit-mocha/index.js
module.exports = api => { api.chainWebpack(webpackConfig => { if (process.env.NODE_ENV === 'test') { webpackConfig.mode('none') webpackConfig.merge({ target: 'node', devtool: 'inline-cheap-module-source-map' }) const { semver, loadModule } = require('@vue/cli-shared-utils...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/ui.js
packages/@vue/cli-plugin-unit-mocha/ui.js
module.exports = api => { api.describeTask({ match: /vue-cli-service test:unit/, description: 'org.vue.mocha.tasks.test.description', link: 'https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-unit-mocha#injected-commands', prompts: [ { name: 'watch', type: 'conf...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/generator/index.js
packages/@vue/cli-plugin-unit-mocha/generator/index.js
/** @type {import('@vue/cli').GeneratorPlugin} */ module.exports = (api, options, rootOptions, invoking) => { const isVue3 = rootOptions && rootOptions.vueVersion === '3' api.render('./template', { isVue3, hasTS: api.hasPlugin('typescript'), hasRouter: api.hasPlugin('router') }) api.extendPackage(...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/generator/template/tests/unit/example.spec.js
packages/@vue/cli-plugin-unit-mocha/generator/template/tests/unit/example.spec.js
<%_ if (!hasTS) { _%> import { expect } from 'chai' <%_ if (!rootOptions.bare || !hasRouter) { _%> import { shallowMount } from '@vue/test-utils' <%_ } else { _%> import { mount, createLocalVue } from '@vue/test-utils' <%_ } _%> <%_ if (!rootOptions.bare) { _%> import HelloWorld from '@/components/HelloWorld.vue' desc...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/__tests__/mochaPluginVue3.spec.js
packages/@vue/cli-plugin-unit-mocha/__tests__/mochaPluginVue3.spec.js
jest.setTimeout(3000000) const createOutside = require('@vue/cli-test-utils/createUpgradableProject') test('should work with Vue 3', async () => { const project = await createOutside('unit-mocha-vue-3', { vueVersion: '3', plugins: { '@vue/cli-plugin-babel': {}, '@vue/cli-plugin-unit-mocha': {} ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/__tests__/mochaPlugin.spec.js
packages/@vue/cli-plugin-unit-mocha/__tests__/mochaPlugin.spec.js
jest.setTimeout(3000000) const createOutside = require('@vue/cli-test-utils/createUpgradableProject') test('should work', async () => { const project = await createOutside('unit-mocha', { plugins: { '@vue/cli-plugin-babel': {}, '@vue/cli-plugin-unit-mocha': {} } }) await project.run(`vue-cli...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-unit-mocha/__tests__/mochaGenerator.spec.js
packages/@vue/cli-plugin-unit-mocha/__tests__/mochaGenerator.spec.js
const generateWithPlugin = require('@vue/cli-test-utils/generateWithPlugin') const create = require('@vue/cli-test-utils/createTestProject') test('base', async () => { const { pkg, files } = await generateWithPlugin([ { id: 'unit-mocha', apply: require('../generator'), options: {} }, //...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-vuex/index.js
packages/@vue/cli-plugin-vuex/index.js
module.exports = (api, options = {}) => {}
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-vuex/generator/index.js
packages/@vue/cli-plugin-vuex/generator/index.js
module.exports = (api, options = {}, rootOptions = {}) => { api.injectImports(api.entryFile, `import store from './store'`) if (rootOptions.vueVersion === '3') { api.transformScript(api.entryFile, require('./injectUseStore')) api.extendPackage({ dependencies: { vuex: '^4.0.0' } }) ...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-vuex/generator/injectUseStore.js
packages/@vue/cli-plugin-vuex/generator/injectUseStore.js
module.exports = (file, api) => { const j = api.jscodeshift const root = j(file.source) const appRoots = root.find(j.CallExpression, (node) => { if (j.Identifier.check(node.callee) && node.callee.name === 'createApp') { return true } if ( j.MemberExpression.check(node.callee) && j....
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-vuex/generator/template-vue3/src/store/index.js
packages/@vue/cli-plugin-vuex/generator/template-vue3/src/store/index.js
import { createStore } from 'vuex' export default createStore({ state: { }, getters: { }, mutations: { }, actions: { }, modules: { } })
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-vuex/generator/template/src/store/index.js
packages/@vue/cli-plugin-vuex/generator/template/src/store/index.js
import Vue from 'vue' import Vuex from 'vuex' Vue.use(Vuex) export default new Vuex.Store({ state: { }, getters: { }, mutations: { }, actions: { }, modules: { } })
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-vuex/__tests__/vuexGenerator.spec.js
packages/@vue/cli-plugin-vuex/__tests__/vuexGenerator.spec.js
const generateWithPlugin = require('@vue/cli-test-utils/generateWithPlugin') test('base', async () => { const { files, pkg } = await generateWithPlugin({ id: 'vuex', apply: require('../generator'), options: {} }) expect(files['src/store/index.js']).toBeTruthy() expect(files['src/store/index.js'])....
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/generator.js
packages/@vue/cli-plugin-babel/generator.js
module.exports = api => { // Most likely you want to overwrite the whole config to ensure it's working // without conflicts, e.g. for a project that used Jest without Babel. // It should be rare for the user to have their own special babel config // without using the Babel plugin already. delete api.generator...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/preset.js
packages/@vue/cli-plugin-babel/preset.js
module.exports = require('@vue/babel-preset-app')
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/index.js
packages/@vue/cli-plugin-babel/index.js
const path = require('path') const babel = require('@babel/core') const { isWindows } = require('@vue/cli-shared-utils') function getDepPathRegex (dependencies) { const deps = dependencies.map(dep => { if (typeof dep === 'string') { const depPath = path.join('node_modules', dep, '/') return isWindows...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/migrator/index.js
packages/@vue/cli-plugin-babel/migrator/index.js
const { chalk } = require('@vue/cli-shared-utils') module.exports = api => { api.transformScript( 'babel.config.js', require('../codemods/usePluginPreset') ) if (api.fromVersion('^3')) { api.extendPackage( { dependencies: { 'core-js': '^3.8.3' } }, { warnI...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/usePluginPreset.js
packages/@vue/cli-plugin-babel/codemods/usePluginPreset.js
module.exports = function (fileInfo, api) { const j = api.jscodeshift const root = j(fileInfo.source) const useDoubleQuote = root.find(j.Literal).some(({ node }) => node.raw.startsWith('"')) root .find(j.Literal, { value: '@vue/app' }) .replaceWith(j.stringLiteral('@vue/cli-plugin-babel/preset')) ro...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__tests__/usePluginPreset.spec.js
packages/@vue/cli-plugin-babel/codemods/__tests__/usePluginPreset.spec.js
jest.autoMockOff() const { defineTest } = require('jscodeshift/dist/testUtils') defineTest(__dirname, 'usePluginPreset', null, 'default') defineTest(__dirname, 'usePluginPreset', null, 'customConfig') defineTest(__dirname, 'usePluginPreset', null, 'require') defineTest(__dirname, 'usePluginPreset', null, 'templateLit...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/templateLiteral.output.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/templateLiteral.output.js
module.exports = { presets: ['@vue/cli-plugin-babel/preset'] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/templateLiteral.input.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/templateLiteral.input.js
module.exports = { presets: [`@vue/app`] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/default.output.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/default.output.js
module.exports = { presets: ['@vue/cli-plugin-babel/preset'] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/require.input.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/require.input.js
const config = { presets: [ [require('@vue/babel-preset-app'), { polyfills: [] }] ] } module.exports = config
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/customConfig.output.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/customConfig.output.js
module.exports = { presets: [ ['@vue/cli-plugin-babel/preset', { polyfills: [] }] ] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/doubleQuote.input.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/doubleQuote.input.js
module.exports = { presets: ["@vue/app"] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/default.input.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/default.input.js
module.exports = { presets: ['@vue/app'] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/require.output.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/require.output.js
const config = { presets: [ [require('@vue/cli-plugin-babel/preset'), { polyfills: [] }] ] } module.exports = config
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/customConfig.input.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/customConfig.input.js
module.exports = { presets: [ ['@vue/app', { polyfills: [] }] ] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/codemods/__testfixtures__/doubleQuote.output.js
packages/@vue/cli-plugin-babel/codemods/__testfixtures__/doubleQuote.output.js
module.exports = { presets: ["@vue/cli-plugin-babel/preset"] }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/__tests__/babelMigrator.spec.js
packages/@vue/cli-plugin-babel/__tests__/babelMigrator.spec.js
const create = require('@vue/cli-test-utils/createUpgradableProject') const { logs } = require('@vue/cli-shared-utils') jest.setTimeout(300000) test('upgrade: plugin-babel v3.5', async () => { const project = await create('plugin-babel-legacy', { plugins: { '@vue/cli-plugin-babel': { version: '3.5...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/__tests__/transpileDependencies.spec.js
packages/@vue/cli-plugin-babel/__tests__/transpileDependencies.spec.js
jest.setTimeout(30000) const fs = require('fs-extra') const path = require('path') const { defaultPreset } = require('@vue/cli/lib/options') const create = require('@vue/cli-test-utils/createTestProject') let project async function readVendorFile () { const files = await fs.readdir(path.join(project.dir, 'dist/js'...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-babel/__tests__/babelRuntime.spec.js
packages/@vue/cli-plugin-babel/__tests__/babelRuntime.spec.js
jest.setTimeout(80000) const { defaultPreset } = require('@vue/cli/lib/options') const create = require('@vue/cli-test-utils/createTestProject') const serve = require('@vue/cli-test-utils/serveWithPuppeteer') // iterableToArray no longer required in babel/runtime 7.8.7+ // test('should add polyfills for code in @babe...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/index.js
packages/@vue/cli-plugin-e2e-webdriverio/index.js
const fs = require('fs') const path = require('path') const { info, chalk, execa } = require('@vue/cli-shared-utils') const { cmdArgs } = require('@wdio/cli/build/commands/run') const CLI_OPTIONS = Object.entries(cmdArgs).reduce((obj, [param, { desc }]) => { obj[`--${param}`] = desc return obj }, {}) /** @type {...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/prompts.js
packages/@vue/cli-plugin-e2e-webdriverio/prompts.js
const { installedBrowsers } = require('@vue/cli-shared-utils') module.exports = [ { name: 'webdrivers', type: `checkbox`, message: `Pick browsers to run end-to-end test on`, choices: [ { name: `Chrome`, value: 'chrome', checked: true }, { name: 'Firef...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/ui.js
packages/@vue/cli-plugin-e2e-webdriverio/ui.js
module.exports = api => { api.describeTask({ match: /vue-cli-service test:e2e/, description: 'org.vue.webdriverio.tasks.test.description', link: 'https://github.com/vuejs/vue-cli', prompts: [], onBeforeRun: () => {} }) }
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/migrator/index.js
packages/@vue/cli-plugin-e2e-webdriverio/migrator/index.js
module.exports = (api) => { if (api.fromVersion('<= 5.0.0-alpha.4')) { api.render((files) => { if (!files['tsconfig.json']) { return } files['tsconfig.json'] = files['tsconfig.json'].replace( '"@wdio/sync"', '"webdriverio/sync"' ) if (!/"expect-webdriverio"/....
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/generator/index.js
packages/@vue/cli-plugin-e2e-webdriverio/generator/index.js
const { installedBrowsers } = require('@vue/cli-shared-utils') const applyTS = module.exports.applyTS = (api, invoking) => { api.extendPackage({ devDependencies: { '@types/mocha': require('../package.json').dependencies['@types/mocha'] } }) // inject types to tsconfig.json if (invoking) { ap...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/generator/template/wdio.local.conf.js
packages/@vue/cli-plugin-e2e-webdriverio/generator/template/wdio.local.conf.js
<%- hasTS ? 'const { config } = require(\'./wdio.shared.conf.ts\')' : 'const { config } = require(\'./wdio.shared.conf\')' %> exports.config = { /** * base config */ ...config, /** * config for local testing */ maxInstances: 1, services: [<%- options.webdrivers.includes('chrome') ?(options.webdri...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/generator/template/wdio.sauce.conf.js
packages/@vue/cli-plugin-e2e-webdriverio/generator/template/wdio.sauce.conf.js
<%- hasTS ? 'import { config } from \'./wdio.shared.conf.ts\'' : 'const { config } = require(\'./wdio.shared.conf\')' %> const BUILD_ID = Math.ceil(Date.now() / 1000) exports.config = { /** * base config */ ...config, /** * config for testing on Sauce Labs */ user: process.env.SAUCE_USERNAME, ke...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false
vuejs/vue-cli
https://github.com/vuejs/vue-cli/blob/7eb93c169c7520935252e2473387f923ef80d856/packages/@vue/cli-plugin-e2e-webdriverio/generator/template/wdio.shared.conf.js
packages/@vue/cli-plugin-e2e-webdriverio/generator/template/wdio.shared.conf.js
/* eslint-disable no-unused-vars, max-len */ const path = require('path') exports.config = { // ================== // Specify Test Files // ================== // Define which test specs should run. The pattern is relative to the directory // from which `wdio` was called. Notice that, if you are calling `wdio...
javascript
MIT
7eb93c169c7520935252e2473387f923ef80d856
2026-01-04T15:01:40.395274Z
false