Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(tutorial): typing functions in tutorial #358

Merged
merged 2 commits into from
Aug 17, 2023
Merged

Conversation

yhsiang
Copy link
Contributor

@yhsiang yhsiang commented Aug 15, 2023

To fix #357

  1. typing tutorial.js
  2. typing handleInput.js
  3. typing handlePostback.js

handlers/*.js should be next target

@yhsiang yhsiang requested a review from MrOrz August 15, 2023 05:46
@yhsiang yhsiang changed the title fix(tutorial): typing functions in tutorial fix #357 fix(tutorial): typing functions in tutorial Aug 15, 2023
@yhsiang yhsiang changed the title fix #357 fix(tutorial): typing functions in tutorial fix(tutorial): typing functions in tutorial Aug 15, 2023
@coveralls
Copy link

coveralls commented Aug 15, 2023

Pull Request Test Coverage Report for Build 5864057925

  • 5 of 5 (100.0%) changed or added relevant lines in 2 files are covered.
  • 2 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.005%) to 91.054%

Files with Coverage Reduction New Missed Lines %
src/webhook/index.ts 2 50.0%
Totals Coverage Status
Change from base Build 5863858587: 0.005%
Covered Lines: 979
Relevant Lines: 1051

💛 - Coveralls

@yhsiang yhsiang marked this pull request as draft August 15, 2023 05:54
@yhsiang yhsiang marked this pull request as ready for review August 16, 2023 05:48
src/webhook/handlers/tutorial.ts Outdated Show resolved Hide resolved
};

export type ChatbotStateHandlerParams = {
data: Context | Record<string, never>;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: mind adding comment for the empty object (Record<string, never>)? It's not straightforward for why it is possible for data to be in this format.

src/types/chatbotState.ts Outdated Show resolved Hide resolved
src/webhook/handlers/tutorial.ts Outdated Show resolved Hide resolved
@johnson-liang johnson-liang merged commit 730a68f into master Aug 17, 2023
0 of 2 checks passed
@johnson-liang johnson-liang deleted the tutorial-ts branch August 17, 2023 05:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Typing handlers/tutorial and removing ts-ignore in webhook index
3 participants