Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

According to TypeScript, siteId is a required property for the createInstance config parameter #235

Closed
AryanJ-NYC opened this issue Sep 1, 2020 · 0 comments · Fixed by #236
Assignees
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed
Milestone

Comments

@AryanJ-NYC
Copy link
Contributor

Describe the bug
According to TypeScript, siteId is a required property for the config parameter in createInstance while, according to the docs, siteId is optional (whose default value is 1). Given the contradiction, either the TypeScript or the docs are incorrect.

To Reproduce
Steps to reproduce the behavior:

  1. Call createInstance with { urlBase: 'https://LINK.TO.DOMAIN' }
  2. See a TypeScript error explaining siteId is required
  3. See the Usage section of the React docs and notice siteId is said to be optional
  4. Be confused 🤔

Expected behavior
TypeScript and the docs live in harmony.

Screenshots
Screen Shot 2020-09-01 at 12 04 59 AM

Desktop (please complete the following information):

  • Version: 0.2.0
AryanJ-NYC added a commit to AryanJ-NYC/matomo-tracker that referenced this issue Sep 1, 2020
@jonkoops jonkoops self-assigned this Sep 1, 2020
@jonkoops jonkoops added bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed labels Sep 1, 2020
@jonkoops jonkoops added this to the 0.2.1 milestone Sep 1, 2020
AryanJ-NYC added a commit to AryanJ-NYC/matomo-tracker that referenced this issue Sep 2, 2020
AryanJ-NYC added a commit to AryanJ-NYC/matomo-tracker that referenced this issue Sep 5, 2020
AryanJ-NYC added a commit to AryanJ-NYC/matomo-tracker that referenced this issue Sep 5, 2020
AryanJ-NYC added a commit to AryanJ-NYC/matomo-tracker that referenced this issue Sep 6, 2020
@jonkoops jonkoops modified the milestones: 0.2.1, 0.3.0 Sep 7, 2020
@jonkoops jonkoops modified the milestones: 1.0.0, 0.3.0 Oct 21, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants