# Disable the template of the subflow

**URL:** <https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932>\
**Category:** General\
**Created:** [19 September 2022 14:29 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932 "2022-09-19T14:29:04Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sztt](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@Sztt](https://discourse.nodered.org/u/Sztt)\
**Post date:** [19 September 2022 14:29 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932/1 "2022-09-19T14:29:04Z")

</div>

Once I have designed the subflow template, how do I disable editing the subflow template? I did this to prevent the subflow template from being broken.

---

<div class="post-metadata">

**Author:** ![Sztt](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@Sztt](https://discourse.nodered.org/u/Sztt)\
**Post date:** [19 September 2022 14:29 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932/2 "2022-09-19T14:29:33Z")

</div>

- Do I need to change the source 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:** [19 September 2022 15:12 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932/3 "2022-09-19T15:12:16Z")

</div>

The only option would be to wrap you subflow as an npm module and then install it as you do other palette nodes.

[https://nodered.org/docs/creating-nodes/subflow-modules](https://nodered.org/docs/creating-nodes/subflow-modules)

There is no way to prevent editing of a subflow template in its original form.

---

<div class="post-metadata">

**Author:** ![Sztt](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@Sztt](https://discourse.nodered.org/u/Sztt)\
**Post date:** [20 September 2022 04:05 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932/6 "2022-09-20T04:05:48Z")

</div>

I tried following the documentation and found nothing to do with the package. There was no packaged subflow on the left. Here is my file, consisting of two JSON files, one JS file (which I changed to TXT for uploadability), and a screenshot of my subflow template, which basically does is read an image and return a value. What did I do wrong? The flow.json is the unpacked json file.  
[flow.json](https://discourse.nodered.org/uploads/short-url/esxf8enT0osNryuYU3gvROPKnwE.json) (2.3 KB)  
[readimg-subflow.txt](https://discourse.nodered.org/uploads/short-url/sp5tHqsFSxlejOacL6qLqClxtd8.txt) (323 Bytes)  
[subflow.json](https://discourse.nodered.org/uploads/short-url/bFsywkI1KR8MG3BIRLu7WMIWtNX.json) (1.9 KB)  
[package.json](https://discourse.nodered.org/uploads/short-url/mMJT1p0GnqRxlY9DJJ4ydima4mG.json) (224 Bytes)

---

<div class="post-metadata">

**Author:** ![Sztt](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@Sztt](https://discourse.nodered.org/u/Sztt)\
**Post date:** [20 September 2022 04:06 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932/7 "2022-09-20T04:06:57Z")

</div>

![1](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/e/3ef250cb8e402b6ea4cafc0c413e29ae73913d42.png)

---

<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:** [19 November 2022 04:07 UTC](https://discourse.nodered.org/t/disable-the-template-of-the-subflow/67932/8 "2022-11-19T04:07:04Z")

</div>

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