Creative Analyzer - v0.0.1
    Preparing search index...

    Function extractFileId

    • Extract the Drive fileId from any of the three documented URL shapes.

      Parameters

      • url: string

        Any Drive share URL (/file/d/{id}/view, /d/{id}/..., ?id={id}).

      Returns string | null

      The extracted file id, or null if no pattern matches.

      extractFileId('https://drive.google.com/file/d/abc123/view') // 'abc123'
      extractFileId('https://example.com') // null