Skip to content

Correction for step test in validateInputProperties function #2406

@alexbartfeld

Description

@alexbartfeld

Stencil version:

@stencil/core@1.13.0-0 

I'm submitting a:

[x] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://stencil-worldwide.herokuapp.com/ or https://forum.ionicframework.com/

Current behavior:
Current input validation function checks index of step parameter against an index of min property.

const validateInputProperties = (vnodeData: any) => {
  const props = Object.keys(vnodeData);
  const typeIndex = props.indexOf('type');
  const minIndex = props.indexOf('min');
  const maxIndex = props.indexOf('max');
  const stepIndex = props.indexOf('min');
  ...

Expected behavior:
Step should be checked against step property.

const validateInputProperties = (vnodeData: any) => {
  const props = Object.keys(vnodeData);
  const typeIndex = props.indexOf('type');
  const minIndex = props.indexOf('min');
  const maxIndex = props.indexOf('max');
  const stepIndex = props.indexOf('step');
  ...

Steps to reproduce:
validateInputProperties function is in src/runtime/vdom/h.ts file

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions