Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code Completion and Intellisense Issues with frida-il2cpp-bridge in Visual Studio Code #448

Open
Mr-Kips opened this issue Dec 14, 2023 · 3 comments

Comments

@Mr-Kips
Copy link

Mr-Kips commented Dec 14, 2023

When using frida-il2cpp-bridge, I encounter issues with code completion, intellisense, and errors related to missing member properties (Property does not exist on type {}).

Problem Overview
Upon integrating frida-il2cpp-bridge into my project via npm, I noticed that it behaves differently compared to other libraries. Specifically, I'm facing issues with code completion and intellisense within Visual Studio Code. Whenever I attempt to access certain members or properties, I receive errors indicating that these properties do not exist on the type.

Screen Shoot

image

Working 100% for other Libraries
this is working 100% for Frida's JS API within same project , same .ts file. Code Intellisense is working 100% for libraries excluding frida-il2cpp-bridge

image

Expected Behavior
I expected frida-il2cpp-bridge to provide complete code hints, intellisense, and proper property recognition within my development environment, similar to other libraries I've used. However, this behavior seems to be absent or inconsistent, resulting in errors during development.

Installation

 npm -i frida-il2cpp-bridge

Additional Information
Code completion and Intellisense is working for other libraries.
I've ensured that the library was installed correctly and is up to date.
I am using TypeScript file for coding my stuff, (.ts)

Project's Packag.json file

{
  "name": "frida-agent-example",
  "version": "1.0.0",
  "description": "Example Frida agent written in TypeScript",
  "private": true,
  "keywords": [
    "frida",
    "il2cpp",
    "dump",
    "trace",
    "global-metadata"
  ],
  "main": "agent/index.ts",
  "scripts": {
    "prepare": "npm run build",
    "spawn": "frida -U Gadget -l _agent.js",
    "build": "frida-compile agent/index.ts -o _agent.js -c",
    "watch": "frida-compile agent/index.ts -o _agent.js -w"
  },
  "devDependencies": {
    "@types/frida-gum": "^18.4.3",
    "@types/node": "^18.19.3",
    "frida-compile": "^15.0.8",
    "typescript": "^5.3.3",
    "frida-il2cpp-bridge": "^0.9.0"
  },
  "dependencies": {
    
  }
}


Project's tsconfig.json file:

{
  "compilerOptions": {
    "target": "es2020",
    "lib": ["es2020"],
    "allowJs": true,
    "noEmit": true,
    "strict": true,
    "esModuleInterop": true,
    "declaration": true,
    "experimentalDecorators": true,
    "sourceMap": true,
    "stripInternal": true,
  }
}

Environment Details:

image

@vfsfitvnm
Copy link
Owner

Uhm, would you try using the setup here?

@Mr-Kips
Copy link
Author

Mr-Kips commented Dec 16, 2023

Uhm, would you try using the setup here?

I've done the setup as described but nothing works for me. after troubleshooting of 2 days I reported this issue on GitHub repo. I described this issue in Frida's Telegram Channel but nobody had any idea about the solution.

Recently I noticed that when I use .JS file to code instead of .TS file the VS Code never show any error but the code intellisense and auto completion still remains disabled for this library, this is just like ignoring the errors - not helpful

@expectedfailure
Copy link

Uhm, would you try using the setup here?

I've done the setup as described but nothing works for me. after troubleshooting of 2 days I reported this issue on GitHub repo. I described this issue in Frida's Telegram Channel but nobody had any idea about the solution.

Recently I noticed that when I use .JS file to code instead of .TS file the VS Code never show any error but the code intellisense and auto completion still remains disabled for this library, this is just like ignoring the errors - not helpful

Hardly relevant, but I found a solution.
You need to delete the file tsconfig.json, and reinitialize the project through the terminal with the command tsc -init
After that autocompletion and highlighting will work correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants