-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Open
Description
New Issue Checklist
- Report security issues confidentially.
- Any contribution is under this license.
- Before posting search existing issues.
Issue Description
TypeScript does not recognize the global Parse object in cloud code, resulting in the error:
Cannot find name 'Parse' when referencing Parse.Cloud. This happens even after installing the parse package and using the recommended import patterns. The Parse object is available at runtime, but TypeScript does not recognize it, making it difficult to write type-safe cloud code.
Steps to reproduce
- Clone the repo: https://github.com/tiavina-mika/parse-server-8-ts-issue
- Run
npm install - Open
src/cloud/main.tsinVS Code. - You will see a
TypeScripterror on any usage ofParse(e.g., Parse.Cloud.beforeSave).
Actual Outcome
TypeScript compilation fails with:
Cannot find name 'Parse'
Expected Outcome
TypeScript should recognize the global Parse object and allow type-safe cloud code development.
Environment
Server
- Parse Server version:
8.2.5 - Operating system:
Windows - Local or remote host:
Local
Database
- System:
MongoDB - Database version:
v4.0.6 - Local or remote host:
local
Logs
cloud/main.ts:XX:XX - error TS2304: Cannot find name 'Parse'.
Metadata
Metadata
Assignees
Labels
No labels