Closed iObject closed 3 years ago
Yep, definitely missed that function. This should be a pretty easy fix. Rather than making a whole separate function to find this, we could just update the regular expression for observerField
to support both.
const regexp = /(\.observeField[ \t]*\(.*?,[ \t]*")([a-z0-9_]+)"\)[ \t]*(?:'.*)*$/gim;
becomes
const regexp = /(\.observeField(?:Scoped)?[ \t]*\(.*?,[ \t]*")([a-z0-9_]+)"\)[ \t]*(?:'.*)*$/gim;
Haven't tested that, but should do the trick. We'll want to add a few unit tests to verify it works.
Add autoprefixing to observeFieldScoped. This method is similar to the observeField() method.
https://developer.roku.com/en-ca/docs/references/brightscript/interfaces/ifsgnodefield.md#observefieldscopedfieldname-as-string-functionname-as-string-infofields-as-object-as-boolean