Hey, I’m a young Shopify developer, and I’m trying to create a Shopify checkout extension where the text the user added should be added to the order note as well. Could you please help me figure this out?
Also, please suggest how I could use
useNote()
import {
reactExtension,
TextField,
} from ‘@shopify/ui-extensions-react/checkout’;
export default reactExtension(
‘purchase.checkout.block.render’,
() => ,
);
function Extension() {
return ;
}
Hello @imabhijithak
You can use the below code to add notes in order
import {
reactExtension,
TextField,
useApplyNoteChange,
} from '@shopify/ui-extensions-react/checkout';
import { Button } from '@shopify/ui-extensions/checkout';
import { useState } from 'react';
export default reactExtension(
'purchase.checkout.block.render',
() =>
If the solution presented meets your needs and addresses your query effectively, I encourage you to accept it as the chosen answer. This will acknowledge the support you received and aid fellow community members in identifying reliable and effective solutions for their similar concerns.
Thank you.