Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(src): fix some typos #5104

Merged
merged 1 commit into from
Mar 6, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/core/observer/dep.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export default class Dep {
}

notify () {
// stablize the subscriber list first
// stabilize the subscriber list first
const subs = this.subs.slice()
for (let i = 0, l = subs.length; i < l; i++) {
subs[i].update()
Expand Down
2 changes: 1 addition & 1 deletion src/platforms/web/runtime/components/transition-group.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
// we force transition-group to update its children into two passes:
// in the first pass, we remove all nodes that need to be removed,
// triggering their leaving transition; in the second pass, we insert/move
// into the final disired state. This way in the second pass removed
// into the final desired state. This way in the second pass removed
// nodes will remain where they should be.

import { warn, extend } from 'core/util/index'
Expand Down
8 changes: 4 additions & 4 deletions src/platforms/web/runtime/modules/transition.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export function enter (vnode: VNodeWithData, toggleDisplay: ?() => void) {
}

const expectsCSS = css !== false && !isIE9
const userWantsControl = getHookAgumentsLength(enterHook)
const userWantsControl = getHookArgumentsLength(enterHook)

const cb = el._enterCb = once(() => {
if (expectsCSS) {
Expand Down Expand Up @@ -197,7 +197,7 @@ export function leave (vnode: VNodeWithData, rm: Function) {
} = data

const expectsCSS = css !== false && !isIE9
const userWantsControl = getHookAgumentsLength(leave)
const userWantsControl = getHookArgumentsLength(leave)

const explicitLeaveDuration: any = toNumber(
isObject(duration)
Expand Down Expand Up @@ -294,12 +294,12 @@ function isValidDuration (val) {
* - a wrapped component method (check ._length)
* - a plain function (.length)
*/
function getHookAgumentsLength (fn: Function): boolean {
function getHookArgumentsLength (fn: Function): boolean {
if (!fn) return false
const invokerFns = fn.fns
if (invokerFns) {
// invoker
return getHookAgumentsLength(
return getHookArgumentsLength(
Array.isArray(invokerFns)
? invokerFns[0]
: invokerFns
Expand Down
4 changes: 2 additions & 2 deletions src/platforms/web/runtime/transition-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@ export function getTransitionInfo (el: Element, expectedType?: ?string): {
hasTransform: boolean;
} {
const styles: any = window.getComputedStyle(el)
const transitioneDelays: Array<string> = styles[transitionProp + 'Delay'].split(', ')
const transitionDelays: Array<string> = styles[transitionProp + 'Delay'].split(', ')
const transitionDurations: Array<string> = styles[transitionProp + 'Duration'].split(', ')
const transitionTimeout: number = getTimeout(transitioneDelays, transitionDurations)
const transitionTimeout: number = getTimeout(transitionDelays, transitionDurations)
const animationDelays: Array<string> = styles[animationProp + 'Delay'].split(', ')
const animationDurations: Array<string> = styles[animationProp + 'Duration'].split(', ')
const animationTimeout: number = getTimeout(animationDelays, animationDurations)
Expand Down
6 changes: 3 additions & 3 deletions src/platforms/weex/framework.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export function createInstance (
}
Object.freeze(weexInstanceVar)

// Each instance has a independent `Vue` mdoule instance
// Each instance has a independent `Vue` module instance
const Vue = instance.Vue = createVueModuleInstance(instanceId, moduleGetter)

// The function which create a closure the JS Bundle will run in.
Expand Down Expand Up @@ -286,7 +286,7 @@ function createVueModuleInstance (instanceId, moduleGetter) {

/**
* Generate native module getter. Each native module has several
* methods to call. And all the hebaviors is instance-related. So
* methods to call. And all the behaviors is instance-related. So
* this getter will return a set of methods which additionally
* send current instance id to native when called. Also the args
* will be normalized into "safe" value. For example function arg
Expand Down Expand Up @@ -314,7 +314,7 @@ function genModuleGetter (instanceId) {
/**
* Generate HTML5 Timer APIs. An important point is that the callback
* will be converted into callback id when sent to native. So the
* framework can make sure no side effect of the callabck happened after
* framework can make sure no side effect of the callback happened after
* an instance destroyed.
* @param {[type]} instanceId [description]
* @param {[type]} moduleGetter [description]
Expand Down
6 changes: 3 additions & 3 deletions src/server/create-bundle-runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function createContext (context) {

function compileModule (files, basedir) {
const compiledScripts = {}
const reoslvedModules = {}
const resolvedModules = {}

function getCompiledScript (filename) {
if (compiledScripts[filename]) {
Expand Down Expand Up @@ -52,8 +52,8 @@ function compileModule (files, basedir) {
return evaluateModule(file, context, evaluatedModules)
} else if (basedir) {
return require(
reoslvedModules[file] ||
(reoslvedModules[file] = resolve.sync(file, { basedir }))
resolvedModules[file] ||
(resolvedModules[file] = resolve.sync(file, { basedir }))
)
} else {
return require(file)
Expand Down