Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

calendarth

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

calendarth - npm Package Compare versions

Comparing version 0.0.5 to 0.0.6

2

bower.json
{
"name": "calendarth",
"version": "0.0.5",
"version": "0.0.6",
"main": "./build/calendarth.min.js",

@@ -5,0 +5,0 @@ "ignore": [

{
"name": "calendarth",
"version": "0.0.5",
"version": "0.0.6",
"description": "Fetch a public Google Calendar using AJAX",

@@ -5,0 +5,0 @@ "main": "./src/",

@@ -55,3 +55,3 @@ # Calendarth

#### calendarth.getEventLink(eventItem)
#### calendarth.getEventUrl(eventItem)

@@ -67,3 +67,3 @@ Will return a url that can be used to add the event to a user's Google Calendar.

var addEventToCal = cal.getEventLink(eventItem);
var addEventToCal = cal.getEventUrl(eventItem);
console.log(addEventToCal);

@@ -75,4 +75,4 @@ });

- **v0.0.5**, *12 Apr 2014*
- Add getEventLink() feature.
- **v0.0.6**, *12 Apr 2014*
- Add getEventUrl() feature.
- **v0.0.3**, *9 Apr 2014*

@@ -79,0 +79,0 @@ - Published to NPM.

@@ -66,16 +66,9 @@ /*

*/
Calendarth.prototype.getEventLink = function(eventItem) {
var out = 'http://www.google.com/calendar/event?action=TEMPLATE&text=';
out += encodeURIComponent(eventItem.summary);
out += '&dates=';
out += encodeURIComponent(eventItem.start.dateTime ?
eventItem.start.dateTime : eventItem.start.date);
out += '/';
out += encodeURIComponent(eventItem.end.dateTime ?
eventItem.end.dateTime : eventItem.end.date);
out += '&details=';
out += encodeURIComponent(eventItem.description);
out += '&location=';
out += encodeURIComponent(eventItem.location);
out += '&trp=false&sprop=name:';
Calendarth.prototype.getEventUrl = function(eventItem) {
var linkParts = eventItem.htmlLink.split('=');
var out = 'http://www.google.com/calendar/event?action=TEMPLATE&tmeid=';
out += linkParts[1];
out += '&tmsrc=';
out += encodeURIComponent(eventItem.organizer.email);
return out;
};
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc