INNER CODE UNIT · TypeScript

TITLE_GENERATION_RESPONSE_REGEX

google-marketing-solutions/feedgen · src/app.ts:50

const TITLE_GENERATION_RESPONSE_REGEX = new RegExp(
  'product attribute keys in original title\\**:[\\s*]*(?<origTemplateRow>.*?)' +
    '[\\s*]*product category\\**:[\\s*]*(?<genCategoryRow>.*?)' +
    '[\\s*]*product attribute keys\\**:[\\s*]*(?<genTemplateRow>.*?)' +
    '[\\s*]*product attribute values\\**:[\\s*]*(?<genAttributesRow>.*?)' +
    '(?:[\\s*]*replaced keys\\**:[\\s*]*(?<replacedKeysRow>.*?))?' +
    '[\\s*]*generated title\\**:[\\s*]*(?<genTitleRow>.*)$',
  'is'
);

/**
 * Handle 'onOpen' Sheets event to show menu.
 */
export function onOpen() {
  SpreadsheetApp.getUi()
    .createMenu('FeedGen')
    .addItem('Launch', 'showSidebar')
    .addToUi();

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…