# TypedInput Change options upon change event

**URL:** <https://discourse.nodered.org/t/typedinput-change-options-upon-change-event/61448>\
**Category:** Developing Nodes\
**Created:** [18 April 2022 15:06 UTC](https://discourse.nodered.org/t/typedinput-change-options-upon-change-event/61448 "2022-04-18T15:06:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jayson](https://avatars.discourse-cdn.com/v4/letter/j/aeb1de/32.png) [@jayson](https://discourse.nodered.org/u/jayson)\
**Post date:** [18 April 2022 15:06 UTC](https://discourse.nodered.org/t/typedinput-change-options-upon-change-event/61448/1 "2022-04-18T15:06:02Z")

</div>

Hi,

How can I change the options of the initialized dropdown for typedinput? the on change event id being triggered but the options are not changing.

Here is my initial creation of the typedinput.

```auto
         var methodsArr = []
          Object.keys(res).forEach(row => {
            methodsArr.push({
              value: row,
              label: row
            })
          })

          $('#node-input-method').typedInput({
            type: 'method',
            types: [
              {
                value: 'method',
                default: method,
                options: methodsArr
              }
            ]
          })

```

here is my onchange event

```auto
$('#node-input-method').on('change', () => {
        console.log(node.args[node.method])
        node.method = $('#node-input-method').val()

        var functionsArr = []
        Object.keys(node.args[node.method]).forEach(row => {
          functionsArr.push({
            value: row,
            label: row
          })
        })
        $('#node-input-webhook').typedInput({
          type: 'webhook',
          types: [
            {
              value: 'webhook',
              default: webhook,
              options: functionsArr
            }
          ]
        })

      })

```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [17 June 2022 15:06 UTC](https://discourse.nodered.org/t/typedinput-change-options-upon-change-event/61448/2 "2022-06-17T15:06:08Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
