Skip to content

Commit

Permalink
chore(all): prepare release 1.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
EisenbergEffect committed Dec 23, 2016
1 parent 8c6cf23 commit 1f4c3e4
Show file tree
Hide file tree
Showing 9 changed files with 53 additions and 15 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-metadata",
"version": "1.0.2",
"version": "1.0.3",
"description": "Utilities for reading and writing the metadata of JavaScript functions.",
"keywords": [
"aurelia",
Expand Down
10 changes: 7 additions & 3 deletions dist/amd/aurelia-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,28 +24,32 @@ define(['exports', 'aurelia-pal'], function (exports, _aureliaPal) {
return target;
};



var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
return typeof obj;
} : function (obj) {
return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
};


function isObject(val) {
return val && (typeof val === 'function' || (typeof val === 'undefined' ? 'undefined' : _typeof(val)) === 'object');
}

var metadata = exports.metadata = {
resource: 'aurelia:resource',
paramTypes: 'design:paramtypes',
propertyType: 'design:type',
properties: 'design:properties',
get: function get(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
var result = metadata.getOwn(metadataKey, target, targetKey);
return result === undefined ? metadata.get(metadataKey, Object.getPrototypeOf(target), targetKey) : result;
},
getOwn: function getOwn(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
return Reflect.getOwnMetadata(metadataKey, target, targetKey);
Expand Down
12 changes: 10 additions & 2 deletions dist/aurelia-metadata.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
import {PLATFORM} from 'aurelia-pal';

function isObject(val) {
return val && (typeof val === 'function' || typeof val === 'object');
}

/**
* Helpers for working with metadata on functions.
*
Expand Down Expand Up @@ -62,12 +66,16 @@ export const metadata: MetadataType = {
propertyType: 'design:type',
properties: 'design:properties',
get(metadataKey: string, target: Function, targetKey?: string): Object {
if (!target) { return undefined; }
if (!isObject(target)) {
return undefined;
}
let result = metadata.getOwn(metadataKey, target, targetKey);
return result === undefined ? metadata.get(metadataKey, Object.getPrototypeOf(target), targetKey) : result;
},
getOwn(metadataKey: string, target: Function, targetKey?: string): Object {
if (!target) { return undefined; }
if (!isObject(target)) {
return undefined;
}
return Reflect.getOwnMetadata(metadataKey, target, targetKey);
},
define(metadataKey: string, metadataValue: Object, target: Function, targetKey?: string): void {
Expand Down
8 changes: 6 additions & 2 deletions dist/commonjs/aurelia-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,24 @@ var _aureliaPal = require('aurelia-pal');



function isObject(val) {
return val && (typeof val === 'function' || (typeof val === 'undefined' ? 'undefined' : _typeof(val)) === 'object');
}

var metadata = exports.metadata = {
resource: 'aurelia:resource',
paramTypes: 'design:paramtypes',
propertyType: 'design:type',
properties: 'design:properties',
get: function get(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
var result = metadata.getOwn(metadataKey, target, targetKey);
return result === undefined ? metadata.get(metadataKey, Object.getPrototypeOf(target), targetKey) : result;
},
getOwn: function getOwn(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
return Reflect.getOwnMetadata(metadataKey, target, targetKey);
Expand Down
8 changes: 6 additions & 2 deletions dist/es2015/aurelia-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,24 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument

import { PLATFORM } from 'aurelia-pal';

function isObject(val) {
return val && (typeof val === 'function' || typeof val === 'object');
}

export const metadata = {
resource: 'aurelia:resource',
paramTypes: 'design:paramtypes',
propertyType: 'design:type',
properties: 'design:properties',
get(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
let result = metadata.getOwn(metadataKey, target, targetKey);
return result === undefined ? metadata.get(metadataKey, Object.getPrototypeOf(target), targetKey) : result;
},
getOwn(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
return Reflect.getOwnMetadata(metadataKey, target, targetKey);
Expand Down
8 changes: 6 additions & 2 deletions dist/native-modules/aurelia-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,24 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol

import { PLATFORM } from 'aurelia-pal';

function isObject(val) {
return val && (typeof val === 'function' || (typeof val === 'undefined' ? 'undefined' : _typeof(val)) === 'object');
}

export var metadata = {
resource: 'aurelia:resource',
paramTypes: 'design:paramtypes',
propertyType: 'design:type',
properties: 'design:properties',
get: function get(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
var result = metadata.getOwn(metadataKey, target, targetKey);
return result === undefined ? metadata.get(metadataKey, Object.getPrototypeOf(target), targetKey) : result;
},
getOwn: function getOwn(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
return Reflect.getOwnMetadata(metadataKey, target, targetKey);
Expand Down
8 changes: 6 additions & 2 deletions dist/system/aurelia-metadata.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ System.register(['aurelia-pal'], function (_export, _context) {



function isObject(val) {
return val && (typeof val === 'function' || (typeof val === 'undefined' ? 'undefined' : _typeof(val)) === 'object');
}

function decorators() {
for (var _len = arguments.length, rest = Array(_len), _key = 0; _key < _len; _key++) {
rest[_key] = arguments[_key];
Expand Down Expand Up @@ -197,14 +201,14 @@ System.register(['aurelia-pal'], function (_export, _context) {
propertyType: 'design:type',
properties: 'design:properties',
get: function get(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
var result = metadata.getOwn(metadataKey, target, targetKey);
return result === undefined ? metadata.get(metadataKey, Object.getPrototypeOf(target), targetKey) : result;
},
getOwn: function getOwn(metadataKey, target, targetKey) {
if (!target) {
if (!isObject(target)) {
return undefined;
}
return Reflect.getOwnMetadata(metadataKey, target, targetKey);
Expand Down
10 changes: 10 additions & 0 deletions doc/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
<a name="1.0.3"></a>
## [1.0.3](https://github.com/aurelia/metadata/compare/1.0.2...v1.0.3) (2016-12-23)


### Bug Fixes

* **metadata:** handle primitive targets ([ecf28dd](https://github.com/aurelia/metadata/commit/ecf28dd)), closes [aurelia/templating-resources#267](https://github.com/aurelia/templating-resources/issues/267) [aurelia/metadata#47](https://github.com/aurelia/metadata/issues/47) [aurelia/binding#551](https://github.com/aurelia/binding/issues/551) [aurelia/dependency-injection#141](https://github.com/aurelia/dependency-injection/issues/141) [aurelia/binding#376](https://github.com/aurelia/binding/issues/376)



<a name="1.0.1"></a>
## [1.0.1](https://github.com/aurelia/metadata/compare/1.0.0...v1.0.1) (2016-10-05)

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-metadata",
"version": "1.0.2",
"version": "1.0.3",
"description": "Utilities for reading and writing the metadata of JavaScript functions.",
"keywords": [
"aurelia",
Expand Down

0 comments on commit 1f4c3e4

Please sign in to comment.