npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

look-at-this

v0.1.14

Published

A very simple collection and lib of social sharing channels

Downloads

2

Readme

LOOK AT THIS

Build Status NPM Version Bower Dependencies Development Dependencies Codacy Badge

About

Just another social sharing plugin. Yeah o.O ... but here are the pros!

  • It is realy realy lightweight. (You only need a css and js file)
  • It is responsive.
  • Customizable link button CSS and template.
  • It works as stand-alone. No jQuery or other libs needed.
  • It respects the users privacy.
  • Any additional JavaScript and CSS code is optional.
  • Supported networks

Responsive showcase

Responsive showcase

Installation

  • npm install look-at-this or bower install look-at-this
  • Import the assets
  • Add a container for the icons called #social-icons

Take a look at examples at

  • https://s-a.github.io/look-at-this/dist (default setup)
  • https://s-a.github.io/look-at-this/index.html

Config networks order and visibility

To get an overview an available list is stored in window.socialIcons.networks (Array of string).
Simply set up a "data-networks" attribute at the #social-icons container to define order and visibilty of share buttons. For example data-networks="email,googleplus,facebook,github,hackernews"

Change share url, title and so on?

By default the settings are stored like this. Each property can be a function.

	// default configuration
	if (!window.socialIcons.setup){
		window.socialIcons.setup = {
			title 	: document.title,
			url 	: location.href,
			subject : "Look at this my friend",
			body 	: function(){
				return "Take a look at this website. It is awesome! " + window.socialIcons.setup.url;
			}
		};
	}

So you can set them to what you need. This informations are masked per social network in the url property at .scream.js for library build. The buildjob bundles them to window.socialIcons.list.

Custom style

There are only two CSS classes to style button layout .social-share-button and .social-icon.

Custom Template

The output of share buttons are base on a simple template. If you need a custom template add a script block like the following to your HTML code.

	<script type="text/html" id="social_icon_template">
	  <% for ( var i = 0; i < icons.length; i++ ) { %>
		<a class="social-share-button" href="#share/<%=icons[i].name%>" target="_blank">
	 		<div class="social-icon social-icon-<%=icons[i].name%>"></div>
		</a>
	  <% } %>
	</script>

Contributing

  • Fork it!
  • Create your feature branch: git checkout -b my-new-feature
  • Commit your changes: git commit -am 'Add some feature'
  • Run the tests: npm test
  • Push to the branch: git push origin my-new-feature
  • Submit a pull request :D

How to add a brand?

  • Install https://github.com/s-a/scream-js
  • Add a file to /ico folder
  • Add the file entry to /ico/.scream.js
  • execute scream .scream.js --build
  • execute node bundle.js
  • execute grunt build
  • execute npm test

Should I add a brand?

Indeed! You can help to make this repo a place containing a well equipped list of share links for social networks.

License

MIT and GPL

Legal

In short, the used logos are registered trademarks and represent only the Companies. They should not be used to represent your products. You may also read the official legal terms of each company.

Credits

Icon Pack by Dan Leech at Simple Icons