Hello i am trying to make a native build for Mac OS. When i do this the editor logs a lot of errors:
I know it happens only if i have a reference to sys.localStorage
in any class which is exported as const.
When i remove sys.localStorage
from my code the editor makes a build without errors.
So here an example:
MainEnums.ts has only one line:
export const test = new Test()
Test.ts:
import {sys} from 'cc'
export class Test {
constructor() {
sys.localStorage.removeItem('test')
const item = sys.localStorage.getItem('test')
sys.localStorage.setItem('test', "null")
}
}