mixins.spec.ts — vue Source File
Architecture documentation for mixins.spec.ts, a typescript file in the vue codebase. 2 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 29345481_4124_5c82_dcdc_9ce40ca8bb03["mixins.spec.ts"] db9e7bef_009d_3918_6e7d_543a36a38d75["vue"] 29345481_4124_5c82_dcdc_9ce40ca8bb03 --> db9e7bef_009d_3918_6e7d_543a36a38d75 90a2398a_1498_3263_c62e_0c064dd2c9b3["index"] 29345481_4124_5c82_dcdc_9ce40ca8bb03 --> 90a2398a_1498_3263_c62e_0c064dd2c9b3 style 29345481_4124_5c82_dcdc_9ce40ca8bb03 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import Vue from 'vue'
import { mergeOptions } from 'core/util/index'
describe('Options mixins', () => {
it('vm should have options from mixin', () => {
const mixin = {
directives: {
c: {}
},
methods: {
a: function () {}
}
}
const vm = new Vue({
mixins: [mixin],
methods: {
b: function () {}
}
})
expect(vm.a).toBeDefined()
expect(vm.b).toBeDefined()
expect(vm.$options.directives.c).toBeDefined()
})
it('should call hooks from mixins first', () => {
const a = {}
const b = {}
const c = {}
const f1 = function () {}
const f2 = function () {}
const f3 = function () {}
const mixinA = {
a: 1,
template: 'foo',
directives: {
a: a
},
created: f1
}
const mixinB = {
b: 1,
directives: {
b: b
},
created: f2
}
const result = mergeOptions(
{},
{
directives: {
c: c
},
template: 'bar',
mixins: [mixinA, mixinB],
created: f3
}
)
expect(result.a).toBe(1)
// ... (91 more lines)
Dependencies
- index
- vue
Source
Frequently Asked Questions
What does mixins.spec.ts do?
mixins.spec.ts is a source file in the vue codebase, written in typescript.
What does mixins.spec.ts depend on?
mixins.spec.ts imports 2 module(s): index, vue.
Where is mixins.spec.ts in the architecture?
mixins.spec.ts is located at test/unit/features/options/mixins.spec.ts (directory: test/unit/features/options).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free