quip-apps-api
Advanced tools
Comparing version 1.0.0-alpha.3 to 1.0.0-alpha.4
15
index.js
@@ -12,12 +12,17 @@ // Copyright Quip 2019 | ||
let global_; | ||
if (typeof window !== "undefined") { | ||
global_ = window; | ||
} else if (typeof global !== "undefined") { | ||
if (typeof global !== "undefined") { | ||
global_ = global; | ||
} else if (typeof self !== "undefined") { | ||
global_ = self; | ||
} else if (typeof window !== "undefined") { | ||
global_ = window; | ||
} else { | ||
global_ = this || {}; | ||
} | ||
module.exports = | ||
global_["quip"] === undefined ? require("./quip") : global_["quip"]; | ||
let quip = global_["quip"]; | ||
if (quip === undefined) { | ||
quip = require("./dist/quip"); | ||
quip.apps.setVersion(require("./package.json").version); | ||
} | ||
module.exports = quip; |
{ | ||
"name": "quip-apps-api", | ||
"version": "1.0.0-alpha.3", | ||
"version": "1.0.0-alpha.4", | ||
"description": "Quip Live Apps API", | ||
"main": "index.js", | ||
"types": "index.d.ts", | ||
"scripts": { | ||
"test": "tape test/**/*.test.js", | ||
"build": "tsc", | ||
"test": "npm run build && tape test/**/*.test.js", | ||
"coveralls": "nyc report --reporter=text-lcov | coveralls", | ||
"lcov": "nyc npm test && nyc report --reporter=lcov" | ||
"lcov": "nyc npm test && nyc report --reporter=lcov", | ||
"prepublishOnly": "npm run build" | ||
}, | ||
@@ -25,2 +28,3 @@ "repository": { | ||
"devDependencies": { | ||
"@types/react": "15.6.27", | ||
"coveralls": "^3.0.6", | ||
@@ -30,5 +34,6 @@ "import-fresh": "^3.1.0", | ||
"react": "^16.9.0", | ||
"tape": "^4.11.0" | ||
"tape": "^4.11.0", | ||
"typescript": "^3.6.3" | ||
}, | ||
"gitHead": "1633a60816f6da91d4b022751e9f3bfd45ae18c1" | ||
"gitHead": "2e7d4f96e972cc99d0eed2456ad9c464c68ba24f" | ||
} |
@@ -39,6 +39,7 @@ # Quip Apps API | ||
without having to perform realistic data manipulation. This is acheived by | ||
exposing a `values` property on all classes, which corresponds to the various | ||
getters on that class. For example, if you want your test to have a record in a | ||
specific state, instead of calling application methods that produce that state, | ||
you can just set it directly on the record: | ||
exposing all editable properties on all classes via `[propertyName]Value` | ||
properties, which correspond to the various getters on that class. For example, | ||
if you want your test to have a record in a specific state, instead of calling | ||
application methods that produce that state, you can just set it directly on the | ||
record: | ||
@@ -49,3 +50,3 @@ ``` | ||
// you can just set these values directly to mock them. | ||
record.values.isDeleted = true | ||
record.isDeletedValue = true | ||
const wrapper = shallow(<RecordView record={record}>) | ||
@@ -52,0 +53,0 @@ expect(wrapper).toMatchSnapshot() |
// Copyright 2019 Quip | ||
const test = require("tape"); | ||
const RecordList = require("../record-list"); | ||
const Record = require("../record"); | ||
const RecordList = require("../dist/record-list").default; | ||
const Record = require("../dist/record").default; | ||
@@ -6,0 +6,0 @@ test("Adding a record to a list", t => { |
// Copyright 2019 Quip | ||
const test = require("tape"); | ||
const Record = require("../record"); | ||
const RecordList = require("../record-list"); | ||
const Record = require("../dist/record").default; | ||
const RecordList = require("../dist/record-list").default; | ||
@@ -6,0 +6,0 @@ test("Default Properties", t => { |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
65962
28
1686
70
7
1