This is a migrated thread and some comments may be shown as answers.

Referencing Javascript Files - Cloud Functions

1 Answer 84 Views
Cloud Code
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
adm
Top achievements
Rank 1
adm asked on 13 Sep 2014, 07:59 AM
Is it possible referencing other javascript files from cloud functions? i need a workaround to do this.

1 Answer, 1 is accepted

Sort by
0
Anton Dobrev
Telerik team
answered on 16 Sep 2014, 09:33 AM
Hi,

Unfortunately, in the current stage this is not possible. We have plans to support this in future releases. However currently we cannot commit to a particular time-frame or to the actual implementation.

At the moment you can include your custom code in the code canvas and use it from within the cloud function. For instance:
function doSomething() {
    return "Hello";
}
 
Everlive.CloudFunction.onRequest(function(request, response, done){
   
   response.body = doSomething();
    done();
});

Thus said you can include a small helper library and use it from the cloud function. Note that this may introduce some overhead in the cloud function's execution time which is limited. You can read more about these restrictions here.

If you have further suggestions you may share them with us in our Feedback portal. The portal is constantly monitored and I can ensure you that we prioritize our development accordingly.

Best regards,
Anton Dobrev
Telerik
 
Everlive is now Telerik Backend Services, and is part of the Telerik Platform.
 
Tags
Cloud Code
Asked by
adm
Top achievements
Rank 1
Answers by
Anton Dobrev
Telerik team
Share this question
or