2.1.0 • Published 1 year ago

coreenmo-social-utilities v2.1.0

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

Requirements

  • Web Browser - Can be used as an emulator to build applications. Example Chrome, Firefox, Safari & Opera.
  • Internet - Because many use CDN and to make it easier to find solutions to all problems.

Example Syntax

const socialSharingUtils = require("social-sharing-utilities");

const url = "https://example.com";
const text = "Check out this link";

const facebookShareUrl = socialSharingUtils.shareOnFacebook(url);
console.log("Share on Facebook:", facebookShareUrl);

const twitterShareUrl = socialSharingUtils.shareOnTwitter(url, text);
console.log("Share on Twitter:", twitterShareUrl);

Explanation

  • shareOnFacebook(url): Generates a URL for sharing the specified URL on Facebook.
  • shareOnTwitter(url, text): Generates a URL for sharing the specified URL and text on Twitter.

Return Value

  • The functions return a string representing the URL for sharing the content on the respective social media platform.
2.1.0

1 year ago

2.0.0

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago