Indent me

This commit is contained in:
Alexander Cerutti
2021-02-05 08:13:22 +01:00
parent d017a38ac9
commit b51b7591bf
4 changed files with 70 additions and 66 deletions

View File

@@ -1,34 +1,36 @@
{ {
"formatVersion": 1, "formatVersion": 1,
"passTypeIdentifier": "pass.com.example.myapp", "passTypeIdentifier": "pass.com.example.myapp",
"serialNumber": "nmyuxofgna", "serialNumber": "nmyuxofgna",
"teamIdentifier": "F53WB8AE67", "teamIdentifier": "F53WB8AE67",
"webServiceURL": "https://192.168.1.254:80/", "webServiceURL": "https://192.168.1.254:80/",
"authenticationToken": "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc", "authenticationToken": "vxwxd7J8AlNNFPS8k0a0FfUFtq0ewzFdc",
"relevantDate": "2011-12-08T13:00-08:00", "relevantDate": "2011-12-08T13:00-08:00",
"locations": [ "locations": [
{ {
"longitude": -122.3748889, "longitude": -122.3748889,
"latitude": 37.6189722 "latitude": 37.6189722
}, },
{ {
"longitude": -122.03118, "longitude": -122.03118,
"latitude": 37.33182 "latitude": 37.33182
} }
], ],
"barcodes": [{ "barcodes": [
"message": "123456789", {
"format": "PKBarcodeFormatQR", "message": "123456789",
"messageEncoding": "iso-8859-1" "format": "PKBarcodeFormatQR",
}], "messageEncoding": "iso-8859-1"
"barcode": { }
"message": "123456789", ],
"format": "PKBarcodeFormatQR", "barcode": {
"messageEncoding": "iso-8859-1" "message": "123456789",
}, "format": "PKBarcodeFormatQR",
"organizationName": "Apple Inc.", "messageEncoding": "iso-8859-1"
"description": "A Booking pass", },
"foregroundColor": "rgb(255, 255, 255)", "organizationName": "Apple Inc.",
"backgroundColor": "rgb(253, 123, 35)", "description": "A Booking pass",
"boardingPass": {} "foregroundColor": "rgb(255, 255, 255)",
"backgroundColor": "rgb(253, 123, 35)",
"boardingPass": {}
} }

View File

@@ -1,25 +1,25 @@
{ {
"name": "examples", "name": "examples",
"version": "0.0.0", "version": "0.0.0",
"description": "Passkit-generator examples", "description": "Passkit-generator examples",
"author": "Alexander P. Cerutti <cerutti.alexander@gmail.com>", "author": "Alexander P. Cerutti <cerutti.alexander@gmail.com>",
"license": "ISC", "license": "ISC",
"scripts": { "scripts": {
"preinstall": "npm run clear:deps && npm unlink --no-save passkit-generator && cd .. && npm run build && npm link && cd examples && npm link passkit-generator", "preinstall": "npm run clear:deps && npm unlink --no-save passkit-generator && cd .. && npm run build && npm link && cd examples && npm link passkit-generator",
"example": "cd build && node", "example": "cd build && node",
"build": "npm run build:clear && npx tsc", "build": "npm run build:clear && npx tsc",
"build:clear": "rm -rf build", "build:clear": "rm -rf build",
"clear:deps": "rm -rf node_modules" "clear:deps": "rm -rf node_modules"
}, },
"dependencies": { "dependencies": {
"express": "^4.17.1", "express": "^4.17.1",
"node-fetch": "^2.6.1", "node-fetch": "^2.6.1",
"tslib": "^2.1.0", "tslib": "^2.1.0",
"passkit-generator": "latest" "passkit-generator": "latest"
}, },
"devDependencies": { "devDependencies": {
"@types/express": "^4.17.0", "@types/express": "^4.17.0",
"@types/node-fetch": "^2.5.0", "@types/node-fetch": "^2.5.0",
"typescript": "^4.1.3" "typescript": "^4.1.3"
} }
} }

14
index.d.ts vendored
View File

@@ -73,7 +73,7 @@ export declare class Pass {
* @param data * @param data
* @returns {Pass} * @returns {Pass}
*/ */
locations(resetFlag: null): this; locations(resetFlag: null): this;
locations(...data: Schema.Location[]): this; locations(...data: Schema.Location[]): this;
/** /**
@@ -93,8 +93,8 @@ export declare class Pass {
* @params data - other barcodes support * @params data - other barcodes support
* @return {this} Improved this with length property and other methods * @return {this} Improved this with length property and other methods
*/ */
barcodes(resetFlag: null): this; barcodes(resetFlag: null): this;
barcodes(message: string): this; barcodes(message: string): this;
barcodes(...data: Schema.Barcode[]): this; barcodes(...data: Schema.Barcode[]): this;
/** /**
@@ -136,10 +136,10 @@ export declare class Pass {
export declare function createAbstractModel(options: Schema.AbstractFactoryOptions): Promise<AbstractModel>; export declare function createAbstractModel(options: Schema.AbstractFactoryOptions): Promise<AbstractModel>;
export declare class AbstractModel { export declare class AbstractModel {
constructor(options: Schema.AbstractModelOptions); constructor(options: Schema.AbstractModelOptions);
readonly certificates: Schema.FinalCertificates; readonly certificates: Schema.FinalCertificates;
readonly bundle: Schema.PartitionedBundle; readonly bundle: Schema.PartitionedBundle;
readonly overrides: Schema.OverridesSupportedOptions; readonly overrides: Schema.OverridesSupportedOptions;
} }
declare namespace Schema { declare namespace Schema {

View File

@@ -1,6 +1,8 @@
{ {
"spec_dir": "spec", "spec_dir": "spec",
"spec_files": [ "**/index.js" ], "spec_files": [
"stopSpecOnExpectationFailure": false, "**/index.js"
"random": true ],
"stopSpecOnExpectationFailure": false,
"random": true
} }