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

sequence-viewer

v0.2.18

Published

A protein sequence viewer written in javascript

Downloads

97

Readme

neXtProt - The knowledge resource on human proteins

This is a code repository for the SIB - Swiss Institute of Bioinformatics CALIPHO group neXtProt project

See: http://www.nextprot.org/

neXtProt sequence viewer

Build Status

The sequence viewer is a super easy javascript library to use in order to draw a protein sequence in a readable way.

Sequence viewer1

Live demo: https://cdn.rawgit.com/calipho-sib/sequence-viewer/master/examples/index.html

Simple example: https://cdn.rawgit.com/calipho-sib/sequence-viewer/master/examples/simple.html

Getting Started

  1. Include the library using bower or npm or simply by including the javascript sequence-viewer.js
//BOWER//
bower install sequence-viewer

//NODE//
npm install sequence-viewer
  1. Specify a div in your html
<div id="sequence-viewer"></div>
  1. Create an instance of Sequence in javascript and apply the render method
//For Node add before : var Sequence = require("sequence-viewer"); //


var seq = new Sequence('MALWMRLLPLLALLALWGPGPGAGSLQPLALEGSLQKRGIVEQCCTSICSLYQLENYCN');
// Render the sequence with or without rendering options
// (Check the interactive documentation)
seq.render('#sequence-viewer');
  1. Et voila!

Sequence viewer2

Note: if you choose the later approach with only the main javascript you should also include the dependencies, jquery,handlebars and bootstrap.min.css

Documentation

Check out this interactive page for a better understanding of how to use the sequence viewer and its possibilities :

  • https://cdn.rawgit.com/calipho-sib/sequence-viewer/master/examples/index.html

Options

  • Show chars per line
  • Wrap lines
  • Highlight
  • Coverage
  • Labels
  • Toolbar (chars per line)
  • Search
  • Title
  • sequenceMaxHeight
  • Events
  • Badge

Examples

https://search.nextprot.org/entry/NX_P01308/view/proteomics

Support

If you have any problem or suggestion please open an issue here.

Development

git clone https://github.com/calipho-sib/sequence-viewer.git

npm install (will install the development dependencies)

bower install (will install the browser dependencies)

...make your changes and modifications...

npm run dist (will create the min & bundle versions in dist/)

npm run build (will create the bundle js & css in build/ for node)

grunt bump (will push and add a new release)

npm publish (will publish in npm)

License

This software is licensed under the GNU GPL v2 license, quoted below.

Copyright (c) 2015, SIB Swiss Institute of Bioinformatics