diff --git a/CHANGELOG.md b/CHANGELOG.md index 2f5eab7..c866bfd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## v0.23.0 + +* Fixed bug in README Stack example +* Updated README instructions on webpage installation + ## v0.22.0 * Added `implies` function diff --git a/README.md b/README.md index a131cbc..2e5de11 100644 --- a/README.md +++ b/README.md @@ -46,15 +46,15 @@ As a dependency run the command: You can also use a specific [version](https://www.npmjs.com/package/@final-hill/decorator-contracts): -`npm install @final-hill/decorator-contracts@0.22.0` +`npm install @final-hill/decorator-contracts@0.23.0` For use in a webpage: -`` +`` With a specific [version](https://www.npmjs.com/package/@final-hill/decorator-contracts@0.22.0): -`` +`` ## Usage @@ -92,7 +92,7 @@ const stackContract = new Contract>({ demands(self){ return !self.isFull(); }, ensures(self, old, item) { return !self.isEmpty() && - self.top === item && + self.top() === item && self.size === old.size + 1; } }, diff --git a/package.json b/package.json index 2665960..d9a92ed 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@final-hill/decorator-contracts", - "version": "0.22.0", + "version": "0.23.0", "description": "Code Contracts for TypeScript and ECMAScript classes", "main": "dist/index.js", "types": "dist/index.d.ts",