What is wrong with my js?

I have a general question regarding my vs code environment.
I am using WSL v2 and everything runs smoothly, just the red underlines that indicates error and Frappe not defined.

The editor suggest to ignore them using: // @ts-ignore, however, it’s not a solution.

Hi @Omar_M_K_Shehada,

Code is right.

Please check it syntax.

frappe.ui.form.on('Your Child Table', {
	field_name_for_trigger: function(frm, cdt, cdn) {
		var row = local[cdt][cdn];
		// Your Code

// Example:
frappe.ui.form.on('Sales Order Item', {
	qty: function(frm, cdt, cdn) {
		var row = local[cdt][cdn];
		frappe.model.set_value(cdt, cdn, 'custom_total_field', row.qty * row.rate);

More reference for:

I hope this helps.

Thank You!

Thank you for responding. I have no issue with the code it self, I just want to adjust the vs code to recognize Frappe and its keywords.

I have found the solution here https://discuss.frappe.io/t/vscode-javascript-settings-to-fix-importing-issues/83789?u=omar_m_k_shehada