File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -11,10 +11,11 @@ See [GitHub’s Developer Guide for the OAuth web application flow](https://deve
1111## Usage
1212
1313``` js
14- const login = require (' @octokit/oauth-login-url' ).default
14+ const { oauthLoginUrl } = require (' @octokit/oauth-login-url' )
15+ // or: import { oauthLoginUrl } from '@octokit/oauth-login-url'
1516
1617// get login URL
17- const { url } = login ({
18+ const { url } = oauthLoginUrl ({
1819 clientId: ' 1234567890abcdef1234'
1920})
2021
@@ -32,7 +33,7 @@ const {
3233 login,
3334 scopes,
3435 state
35- } = login ({
36+ } = oauthLoginUrl ({
3637 clientId: ' 1234567890abcdef1234' ,
3738 redirectUri: ' https://example.com' ,
3839 login: ' octocat' ,
@@ -55,7 +56,7 @@ const myLogin = login.defaults({
5556 client: ' 1234567890abcdef1234'
5657})
5758
58- location .href = myLogin ().url
59+ location .href = oauthLoginUrl ().url
5960```
6061
6162## Options
@@ -150,7 +151,7 @@ location.href = myLogin().url
150151
151152## Result
152153
153- ` login ()` returns an object with the following properties
154+ ` oauthLoginUrl ()` returns an object with the following properties
154155
155156<table >
156157 <thead align =left >
You can’t perform that action at this time.
0 commit comments