deep-foundation / deep-foundation/deepcase-app

"Require" is not highlighted in the editor, even though it is being used.

Open
#199 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
TypeScript
Stars
10
Forks
6
PR merge metrics
No merged PRs in 30d

Description

### Describe the bug

"require" word not hightlighted.

![image](https://github.com/deep-foundation/deepcase-app/assets/1426876/4227cc2d-9995-4132-8f99-fe154373cd11)

### Expected Behavior

Need to use handler with text:
```js
async ({
deep, require,
data: {newLink: {
id: setWebhookLinkId,
from_id: hostLinkId,
to_id: tokenLinkId
}}
}) => {

const typeIdTelegram = await deep.id("@l4legenda/telegram", "Token");

const {data: [{value:{value: hostValue}}]} = await deep.select({
id: hostLinkId,
})

const {data: telegramLinkToken} = await deep.select({
type_id: typeIdTelegram
})

if (telegramLinkToken.length === 0) {
throw new Error(`${setWebhookLinkId} must have contained a link of type ${typeIdTelegram}`)
}
const [{value:{value: tokenValue}}] = telegramLinkToken;

const axios = require('axios');
const result = await axios.post("https://api.telegram.org/bot"+tokenValue+"/setWebhook",{
url: `${hostValue}/messages`,
});

return result.data
}
```

### Current Behavior

_No response_

### Steps to reproduce

_No response_

### Environment

deepcase 0.0.29

Contributor guide

No contributing guide indexed for this repository

Research direction

Start in the deepcase editor's syntax-highlighting entry point and reproduce the issue with the JavaScript handler shown in the report, using deepcase 0.0.29 as the reference environment. Trace how the editor classifies require and verify that the word is highlighted when used in the handler. Done means the reported require usage receives the expected highlighting without breaking other editor highlighting.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
developer-experience, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.