Open triwav opened 5 years ago
@triwav could you provide a link to the docs where it specifies the possible options for this? I'm fine with either of your suggested approaches, but I just want to see all of the possibilities before I implement a fix.
I found your exact example here: https://developer.roku.com/en-gb/docs/references/brightscript/language/component-architecture.md#script-libraries
Are there any others?
@TwitchBronBron there is only one https://developer.roku.com/docs/references/brightscript/language/component-architecture.md#v30bslcorebrs
I did some on-device research into this. Here are my findings:
Library "v30/bslCore.brs"
statement can appear in any in-scope script file, and those functions will be made available to the entire scope.Library "v30/bslCore.brs"
statement is declared in a parent component, child components who extend that parent will also have those functions available.<script uri="common:/LibCore/v30/bslCore.brs"/>
rather than using the Library
statement.
warns about the file not existing. Could either search for anything beginning with common:/ and not search for it or make a whilelist of accepted files. Think there are only 2 or 3 maybe.