Wix coding - help with simple code

I have been trying to use Wix code to get user input, then display items from a database using the user input without success. I feel like I am just missing something. So I simplified my wix code down to the minimum to see if I can figure out where I am going wrong. Now I am just trying to display a table using wix code (yes, I know I can display a table without wix code). But displaying a filtered table is eventually what I want to do, based on user input. Here is my very simple code to display only one column in a table. It is not working. I have a table1 defined. I have a dataset defined that is connected to table1. Below is my code. But nothing happens. What am I doing wrong?

import wixData from ‘wix-data’;
$w.onReady( function () {
$w(“#table1”.columns = [{
“id”: “col1”,
“dataPath”: “firstname”,
“label”: “firstname”,
“width”: 100,
“visible”: true ,
“type”: “string”,}])
})

I will be happy to pay someone to help me solve this problem.

Hi!

I assume you get some kind of error.
Can you please post it?
Plus, share a link to your site and one of us, the WixCode team can inspect it and provide you with a solution.

Doron.