Update input field in svelte component

I try to receive outputs from Amazons MTurk. My code is written in Svelte.

<script lang="ts">
    import { onMount } from "svelte";
    let clickP = {
        x: -1, 
        y: -1
    };
    let randomId = Math.random().toString(36).substring(7);
    let assignmentId = "";
    onMount(() => {
        const urlParams = new URLSearchParams(window.location.search);
        assignmentId = urlParams.get("assignmentId") || "";
        console.log("Assignment ID:", assignmentId); // Debugging output
    });
    const submitForm = () => {
        const form = document.getElementById("mturk_form");
        if (assignmentId !== ""){
            form.submit();
            alert("Form submitted!");
        } else {
            alert("Assignment ID missing!");
        }
    };

</script>
<main>
        <form 
            name="mturk_form" 
            method="POST" 
            id="mturk_form" 
            action="https://workersandbox.mturk.com/mturk/externalSubmit"
        >
            <input type="hidden" value={assignmentId} name="assignmentId" />
            <div class="coordinates">
                <label>x:
                <input 
                    id={'x_' + randomId}
                    name={'taskId_' + $currentTaskStore.taskId + '_frameIndex_' + frameIndex + '_x'} 
                    type="text"
                    bind:value={clickP.x}
                /></label>
                <button type="button" on:click={submitForm}>Submit</button>
</main>

Although my input fields configured correctly with the form, I get only the field test, and the fields marked as variable-feed from the index file.

index.html

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1.0" />
        <script type="module" src="/src/main.js"></script>
        <script src="https://s3.amazonaws.com/mturk-public/externalHIT_v1.js" type="text/javascript"></script>
        <title>Questions</title>
    </head>
    <body>

        <div style="height: 0; width: 0; opacity: 0;">
            <code class="variable-feed">
                ${id_1} :;: ${frameCount_1}
            </code>
            <code class="variable-feed">
                ${id_2} :;: ${frameCount_2}
            </code>
            <code class="variable-feed">
                ${id_3} :;: ${frameCount_3}
            </code>
            <code class="variable-feed">
                ${id_4} :;: ${frameCount_4}
            </code>
            <code class="variable-feed">
                ${id_5} :;: ${frameCount_5}
            </code>
        </div>



        <div id="app"></div>
        <input style="height: 0;" type="hidden" name="test"></input>
        <!----    important commands for Amazon MTurk ----------------->
        <script language="Javascript">
            turkSetAssignmentID();
        </script>
        <!------------------------------------------------------------->
    </body>

    
</html>

I expect the output to include a x column with value -1, in this case.
What should I do to get the outputs?

To update an input field in a Svelte component, you can use the bind directive to create a two-way binding between the input field and a variable in your component’s script.

Here’s an example:

svelte
<script>
  let name = 'World';
</script>

<input bind:value={name} />

In this example, the bind:value directive creates a two-way binding between the value property of the input field and the name variable in the script. When the user types something in the input field, the name variable will be updated automatically.

If you want to update the input field programmatically, you can simply update the name variable in your script, and the input field will be updated automatically.

For example:

svelte
<script>
  let name = 'World';

  function updateName() {
    name = 'New Name';
  }
</script

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật