Skip to content

Parse queryString and extract each utm parameters

Notifications You must be signed in to change notification settings

MalguyMQ/utm-extractor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Install utm-extractor

yarn add utm-extractor or npm install utm-extractor --save

Usage

import {Utm} from 'utm-extractor'
const utm = new Utm('?utm_source=Google&utm_medium=cpc&utm_campaign=spring_sale&utm_term=running+shoes&utm_content=logolink')
const values = utm.get()

console.log(values)

{
    utm_source : "Google",
    utm_medium: "cpc",     
    utm_campaign: "spring_sale",
    utm_term: 'running+shoes',
    utm_content: 'logolink'
}

About

Parse queryString and extract each utm parameters

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published