question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot read property 'charCodeAt' of undefined at isInteger

See original GitHub issue

I am facing an issue on my lightning component in the part which dynamically creates another component based on

$A.createComponent("<component_name>",{
"SObjectName": "f42_Signup__c"
}, function (content, status) {});

Whenever I hover the mouse over SObjectName the output panel opens up and shows this error message: Cannot read property ‘charCodeAt’ of undefined at isInteger

Same thing happens for this piece of code:

component.find('notifLib').showToast({
                    "variant": "error",
                    "title": "Error",
                    "message": "Incomplete"
                });

Hovering mouse over any of the variant,title or message opens the output panel and shows the error. I have recorded a video for the same.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
jprichtercommented, Jul 12, 2019

Happens to me also on v46.5.0. Whenever my mouse goes over the code for creating a force:createRecord event, this error shows in the Output

[Error - 1:18:49 PM] TypeError: Cannot read property 'charCodeAt' of undefined
    at isInteger (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/infer.js:547:18)
    at exports.Obj.hasProp (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/infer.js:581:11)
    at findExprType (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:914:28)
    at findTypeAtExpr (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:927:16)
    at Object.findTypeAt [as run] (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:951:22)
    at run (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:275:59)
    at /my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:278:16
    at Object.exports.withContext (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/infer.js:883:18)
    at /my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:274:13
    at analyzeAll (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:404:15)
TypeError: Cannot read property 'charCodeAt' of undefined
    at isInteger (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/infer.js:547:18)
    at exports.Obj.hasProp (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/infer.js:581:11)
    at findExprType (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:914:28)
    at findTypeAtExpr (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:927:16)
    at Object.findTypeAt [as run] (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:951:22)
    at run (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:275:59)
    at /my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:278:16
    at Object.exports.withContext (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/infer.js:883:18)
    at /my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:274:13
    at analyzeAll (/my_file_path/.vscode/extensions/salesforce.salesforcedx-vscode-lightning-46.5.0/node_modules/aura-language-server/lib/tern/lib/tern.js:404:15)
0reactions
jeffb-sfdccommented, Apr 1, 2022

The associated work item is W-6161498

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: Cannot read property 'charCodeAt' of undefined ...
I'm updating a Facebook ChatBot to DialogFlow Version 2. I have a problem with buttons, they don't work the first time, but if...
Read more >
Cannot read property 'charCodeAt' of undefined - Bountysource
When I write the code like this angular.module('demo', []) .config(myProvider => { myProvider.foo = 'bar'; });.
Read more >
pdfMake [Cannot read property 'charCodeAt' of undefined] - help
Hello comunity, please helpme with this big problem. I want use pdfMake in server side in meteor It all started when I imported...
Read more >
JavaScript String charCodeAt() Method - W3Schools
Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. While using W3Schools, you ......
Read more >
StringView - Javascript - CodeProject Reference
In the past, this had to be simulated by treating the raw data as a string and using the charCodeAt() method to read...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found