Browse Source

naming updates

Evan You 10 years ago
parent
commit
18b90e9243

File diff suppressed because it is too large
+ 242 - 165
dist/vue.js


File diff suppressed because it is too large
+ 0 - 0
dist/vue.min.js


+ 1 - 1
src/compiler/compile.js

@@ -258,7 +258,7 @@ function compileNode (node, options) {
 function compileElement (el, options) {
   // preprocess textareas.
   // textarea treats its text content as the initial value.
-  // just bind it as a v-attr directive for value.
+  // just bind it as an attr directive for value.
   if (el.tagName === 'TEXTAREA') {
     var tokens = textParser.parse(el.value)
     if (tokens) {

+ 1 - 1
src/directive.js

@@ -167,7 +167,7 @@ Directive.prototype._checkDynamicLiteral = function () {
  * we wrap up the expression and use it as the event
  * handler.
  *
- * e.g. v-on="click: a++"
+ * e.g. on-click="a++"
  *
  * @return {Boolean}
  */

+ 0 - 1
src/directives/element/partial.js

@@ -1,5 +1,4 @@
 var _ = require('../../util')
-var textParser = require('../../parsers/text')
 var FragmentFactory = require('../../fragment/factory')
 var vIf = require('../public/if')
 

+ 0 - 12
src/directives/internal/class.js

@@ -4,18 +4,6 @@ var removeClass = _.removeClass
 
 module.exports = {
 
-  // TODO: remove unnecessary logic in 1.0.0
-
-  bind: function () {
-    // interpolations like class="{{abc}}" are converted
-    // to v-class, and we need to remove the raw,
-    // uninterpolated className at binding time.
-    var raw = this._descriptor._rawClass
-    if (raw) {
-      this.prevKeys = raw.trim().split(/\s+/)
-    }
-  },
-
   update: function (value) {
     if (this.arg) {
       // single toggle

+ 1 - 1
src/directives/internal/on.js

@@ -63,7 +63,7 @@ module.exports = {
   update: function (handler) {
     if (typeof handler !== 'function') {
       process.env.NODE_ENV !== 'production' && _.warn(
-        'Directive v-on="' + this.arg + ': ' +
+        'on-"' + this.arg + '="' +
         this.expression + '" expects a function value, ' +
         'got ' + handler
       )

+ 0 - 1
src/directives/public/for.js

@@ -1,5 +1,4 @@
 var _ = require('../../util')
-var config = require('../../config')
 var FragmentFactory = require('../../fragment/factory')
 var isObject = _.isObject
 var uid = 0

+ 1 - 1
test/unit/specs/directives/internal/attr_spec.js

@@ -2,7 +2,7 @@ var _ = require('../../../../../src/util')
 var def = require('../../../../../src/directives/internal/attr')
 
 if (_.inBrowser) {
-  describe('v-attr', function () {
+  describe('attr', function () {
 
     var el, dir
     beforeEach(function () {

+ 1 - 1
test/unit/specs/directives/internal/class_spec.js

@@ -2,7 +2,7 @@ var _ = require('../../../../../src/util')
 var def = require('../../../../../src/directives/internal/class')
 
 if (_.inBrowser) {
-  describe('v-class', function () {
+  describe('bind-class', function () {
 
     var el
     beforeEach(function () {

+ 1 - 1
test/unit/specs/directives/internal/style_spec.js

@@ -18,7 +18,7 @@ function checkPrefixedProp (prop) {
 }
 
 if (_.inBrowser) {
-  describe('v-style', function () {
+  describe('bind-style', function () {
 
     var el, dir
     beforeEach(function () {

Some files were not shown because too many files changed in this diff