-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into feature/first_command
- Loading branch information
Showing
24 changed files
with
171 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,11 @@ | ||
module.exports = { | ||
"parser": "babel-eslint", | ||
"extends": "standard", | ||
"plugins": [], | ||
rules: { | ||
'no-return-await': 0, | ||
'space-before-function-paren': ["error", { | ||
"anonymous": "always", | ||
"named": "never", | ||
"asyncArrow": "always" | ||
}] | ||
} | ||
extends: 'standard', | ||
rules: { | ||
'no-return-await': 0, | ||
'space-before-function-paren': ['error', { | ||
anonymous: 'always', | ||
named: 'never', | ||
asyncArrow: 'always' | ||
}] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<a name="1.1.9"></a> | ||
## 1.1.9 (2018-06-30) | ||
|
||
|
||
### Bug Fixes | ||
|
||
* more strict fuse options ([979a019](https://github.com/fletcherist/yandex-dialogs-sdk/commit/979a019)) | ||
* searchRegexps always returns true ([c266eac](https://github.com/fletcherist/yandex-dialogs-sdk/commit/c266eac)) | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
const Alice = require('../src/index') | ||
const alice = new Alice() | ||
|
||
const aliceCorsMiddleware = (params) => { | ||
return ctx => { | ||
if (ctx.server) { | ||
ctx.server.use(function(req, res, next) { | ||
res.header('Access-Control-Allow-Origin', '*') | ||
res.header('Access-Control-Allow-Headers', 'Origin, X-Requested-With, Content-Type, Accept') | ||
next() | ||
}) | ||
} | ||
} | ||
} | ||
// now all requests will be answered with | ||
// with cors headers | ||
alice.use(aliceCorsMiddleware()) | ||
|
||
// Example for pure strings #1 | ||
alice.command('дай совет', async (ctx) => { | ||
ctx.reply('Make const not var') | ||
}) | ||
|
||
const port = 8080 | ||
alice.listen('/', port).then(console.log('listening on:', port)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
module.exports.ALICE_PROTOCOL_VERSION = '1.0' | ||
module.exports.DEFAULT_END_SESSION = false | ||
module.exports.DEFAULT_END_SESSION = false |
Oops, something went wrong.