Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/page

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/page - npm Package Compare versions

Comparing version 1.8.0 to 1.11.0

41

page/index.d.ts

@@ -1,10 +0,11 @@

// Type definitions for page v1.8.6
// Project: http://visionmedia.github.io/page.js/
// Definitions by: Alan Norbauer <http://alan.norbauer.com/>
// Type definitions for page 1.11
// Project: https://github.com/visionmedia/page.js
// Definitions by: Alan Norbauer <https://github.com/altano/>
// James Garbutt <https://github.com/43081j>
// Piotr Błażejewicz <https://github.com/peterblazejewicz>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.1
declare namespace PageJS {
interface Static {
create(options?: Partial<Options>): Static;
/**

@@ -14,3 +15,3 @@ * Expose Route

*/
Route: Route
Route: Route;
/**

@@ -20,3 +21,3 @@ * Export Context

*/
Context: Context
Context: Context;
/**

@@ -89,3 +90,4 @@ * Defines a route mapping path to the given callback(s).

/**
* Calling page.redirect with only a string as the first parameter redirects to another route. Waits for the current route to push state and after replaces it with the new one leaving the browser history clean.
* Calling page.redirect with only a string as the first parameter redirects to another route.
* Waits for the current route to push state and after replaces it with the new one leaving the browser history clean.
*

@@ -173,2 +175,7 @@ * page('/default', function(){

exit(callback: Callback): void;
/**
* This is the click handler used by page to handle routing when a user clicks an anchor like `<a href="/user/profile">`
*/
clickHandler(e: MouseEvent): void;
}

@@ -182,3 +189,3 @@

*/
new (path: string, options?: RouteOptions): Route
new (path: string, options?: RouteOptions): Route;
/**

@@ -188,3 +195,3 @@ * Return route middleware with the given callback `fn()`.

*/
middleware(fn: Callback): Callback
middleware(fn: Callback): Callback;
/**

@@ -196,3 +203,3 @@ * Check if this route matches `path`, if so populate `params`.

*/
match(path: string, params?: {}): boolean
match(path: string, params?: {}): boolean;
}

@@ -205,3 +212,3 @@

*/
sensitive?: boolean
sensitive?: boolean;
/**

@@ -211,3 +218,3 @@ * enable strict matching for trailing slashes

*/
strict?: boolean
strict?: boolean;
}

@@ -233,5 +240,9 @@

/**
* remove URL encoding frfrom path components
* remove URL encoding from path components
*/
decodeURLComponents: boolean;
/**
* provide a window to control (by default it will control the main window)
*/
window: Window;
}

@@ -252,3 +263,3 @@

*/
new (path: string, state?: any): Context
new (path: string, state?: any): Context;
[idx: string]: any;

@@ -262,3 +273,3 @@ /**

*/
pushState: () => void
pushState: () => void;
/**

@@ -265,0 +276,0 @@ * If true, marks the context as handled to prevent default 404 behaviour. For example this is useful for the routes with interminate quantity of the callbacks.

{
"name": "@types/page",
"version": "1.8.0",
"version": "1.11.0",
"description": "TypeScript definitions for page",

@@ -9,3 +9,4 @@ "license": "MIT",

"name": "Alan Norbauer",
"url": "http://alan.norbauer.com/"
"url": "https://github.com/altano",
"githubUsername": "altano"
},

@@ -16,13 +17,20 @@ {

"githubUsername": "43081j"
},
{
"name": "Piotr Błażejewicz",
"url": "https://github.com/peterblazejewicz",
"githubUsername": "peterblazejewicz"
}
],
"main": "",
"types": "index.d.ts",
"repository": {
"type": "git",
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git"
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
"directory": "types/page"
},
"scripts": {},
"dependencies": {},
"typesPublisherContentHash": "f8717837f32aefbef8d0d6112be65605753d9a98d2ff47f09418414f5f8f94e4",
"typeScriptVersion": "2.1"
"typesPublisherContentHash": "e9f9d5ffaff68ad4de689c173e7aa9825c4ac88452d1440c530761754a28ec52",
"typeScriptVersion": "3.3"
}

@@ -5,13 +5,13 @@ # Installation

# Summary
This package contains type definitions for page (http://visionmedia.github.io/page.js/).
This package contains type definitions for page (https://github.com/visionmedia/page.js).
# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/page
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/page.
Additional Details
* Last updated: Fri, 31 Aug 2018 23:03:07 GMT
### Additional Details
* Last updated: Wed, 02 Dec 2020 22:01:32 GMT
* Dependencies: none
* Global values: page
* Global values: `page`
# Credits
These definitions were written by Alan Norbauer <http://alan.norbauer.com/>, James Garbutt <https://github.com/43081j>.
These definitions were written by [Alan Norbauer](https://github.com/altano), [James Garbutt](https://github.com/43081j), and [Piotr Błażejewicz](https://github.com/peterblazejewicz).

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc