Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Solved
  • Unsolved
  • Users
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Darkly)
  • No Skin
Collapse
brainCloud Forums
  1. Home
  2. Suggestions
  3. Feature Suggestions
  4. Shared Scripts not working

Shared Scripts not working

Scheduled Pinned Locked Moved Feature Suggestions
shared-scripts
3 Posts 2 Posters 1.7k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    Carson Herrick
    wrote on last edited by
    #1

    Re: Shared Modules - Ability to share code between cloud scripts
    I am using

    "use strict";
    bridge.include("external_script_name.ccjs");
    

    But when I try to use it, the web editor gives me an error
    'external_function_name' is not defined.
    I know the external function is all good. The error goes away, when I copy it locally.

    1 Reply Last reply
    0
    • J Offline
      J Offline
      JasonL
      bitHeads
      wrote on last edited by
      #2

      I copied your scripts to my app, tested, it works without any problem.

      So, I guess you see the "getPremadeDeck_Dark_001 is not defined" from the editor warning when you hover over your cursor to the triangle warning icon? Actually, You can just ignore it or comment out the "use strict".

      C 1 Reply Last reply
      0
      • J JasonL

        I copied your scripts to my app, tested, it works without any problem.

        So, I guess you see the "getPremadeDeck_Dark_001 is not defined" from the editor warning when you hover over your cursor to the triangle warning icon? Actually, You can just ignore it or comment out the "use strict".

        C Offline
        C Offline
        Carson Herrick
        wrote on last edited by
        #3

        @JasonL
        I can confirm they are working despite a warning, in strict mode.
        Thanks!

        1 Reply Last reply
        0

        Hello! It looks like you're interested in this conversation, but you don't have an account yet.

        Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

        With your input, this post could be even better 💗

        Register Login
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Solved
        • Unsolved
        • Users