# "TriangleCreateTool is not a constructor" error while create custom annotation

**URL:** <https://pdfjs.community/t/trianglecreatetool-is-not-a-constructor-error-while-create-custom-annotation/231>\
**Category:** Technical Support\
**Created:** [August 27, 2020, 9:48am UTC](https://pdfjs.community/t/trianglecreatetool-is-not-a-constructor-error-while-create-custom-annotation/231 "2020-08-27T09:48:32Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![maharoh9841](https://yyz1.discourse-cdn.com/flex031/user_avatar/pdfjs.community/maharoh9841/32/88_2.png) [@maharoh9841](https://pdfjs.community/u/maharoh9841)\
**Post date:** [August 27, 2020, 9:48am UTC](https://pdfjs.community/t/trianglecreatetool-is-not-a-constructor-error-while-create-custom-annotation/231/1 "2020-08-27T09:48:32Z")

</div>

**Detailed description of issue**  
I get the following error while creating custom annotation while following this guide [https://pdfjs.express/documentation/annotation/custom-annotations](https://pdfjs.express/documentation/annotation/custom-annotations)  
I am using Angular 9 to load the WebViewer

 ![image](https://canada1.discourse-cdn.com/flex031/uploads/pdfjscommunity/original/1X/eb2159c40f7cb201d1843979b8998c2ab4445eaa.png)

Can you please provide angular sample or guide for custom annotations if possible?

**Link to document**  
Here’s my config file for the custom annotation  
[myConfig.zip](https://pdfjs.community/uploads/short-url/pEZARezqGgxdRsu9GZN8CuDbjjh.zip) (1.1 KB)

**Code snippet**  
This is how I am calling the config file in my WebViewer  
WebViewer(  
{  
path: “…/lib/public”,  
config: “…/assets/myConfig.js”,  
},  
this.viewer.nativeElement  
);

---

_[View the full topic](https://pdfjs.community/t/trianglecreatetool-is-not-a-constructor-error-while-create-custom-annotation/231)._
