# Now to add new expression to the expression list?

**URL:** <https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896>\
**Category:** General\
**Created:** [29 August 2019 11:20 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896 "2019-08-29T11:20:12Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![fangzhu](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fangzhu/32/5796_2.png) [@fangzhu](https://discourse.nodered.org/u/fangzhu)\
**Post date:** [29 August 2019 11:20 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896/1 "2019-08-29T11:20:12Z")

</div>

Some core nodes support expressions, such as debug, sort etc.  
I want to create my own node using similar method, and add my own expressions.  
Any examples to do that?

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [29 August 2019 11:34 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896/2 "2019-08-29T11:34:56Z")

</div>

Hi @fangzhu

could you explain a bit more on what you want to do?

The 'expression' option is a standard option available with the TypedInput widget many of the nodes use.

When you say you want to add your own expressions, what sort of thing do you mean?

---

<div class="post-metadata">

**Author:** ![fangzhu](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fangzhu/32/5796_2.png) [@fangzhu](https://discourse.nodered.org/u/fangzhu)\
**Post date:** [29 August 2019 11:41 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896/3 "2019-08-29T11:41:10Z")

</div>

Hi @knolleary  
We have some use case that require adding new data by manipulating existing string, timestamp etc. So I wonder if I can create my own js that can be used as a plugin and added into the existing expression list, it will be helpful.  
I understand this kind of requirements can be achieved by using function code. But people that create the flow does not have programming skills, so expressions could help them to create their "code".

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [29 August 2019 11:53 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896/4 "2019-08-29T11:53:09Z")

</div>

Do you mean you'd like to add custom entries to the list of available types in the TypedInput within your node?

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/9/9f2acea08ba199146b30cce4d472d59aa365b7dd.png)

If is _not_ possible to add to that list in other nodes - for example, you cannot add new entries to the Inject or Change nodes. But you can add entries to the list in your own node.

---

<div class="post-metadata">

**Author:** ![fangzhu](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fangzhu/32/5796_2.png) [@fangzhu](https://discourse.nodered.org/u/fangzhu)\
**Post date:** [29 August 2019 12:30 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896/5 "2019-08-29T12:30:59Z")

</div>

hi @knolleary  
Sorry that I didn't explain that clearly.  
I mean adding my own $expression into this list

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/d/d19355cb61d24bc90dc483b990997ea7068a74bc.png)

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [29 August 2019 13:44 UTC](https://discourse.nodered.org/t/now-to-add-new-expression-to-the-expression-list/14896/6 "2019-08-29T13:44:33Z")

</div>

Ahh - you want to add custom JSONata Functions.

This has come up before - it would be nice to be able to do, but it isn't not currently possible.

Nick
