Ram Chander
Ram Chander

Reputation: 1522

Zendesk - How to include custom js file in client side app?

I am trying create Clint side in Zendesk framework. I want to include custom js file to perform some action (to keep it separate).

directory structure

app-folder
    assets
        iframe.html
        .
        .
    sevices
        userServices.js
    tmp
    translations
        en.json
    manifest.json

I have included file like following (in iframe.html)

<script src="/base-app/services/userServices.js"></script>

i am getting following error

GET http://localhost:4567/base-app/services/userServices.js net::ERR_ABORTED 404 (Not Found)

Upvotes: 0

Views: 324

Answers (1)

ahmedsabriz
ahmedsabriz

Reputation: 412

Move the 'services' folder under 'assets' and update the script tag to

<script src="services/userServices.js"></script>

Upvotes: 1

Related Questions