Giter Site home page Giter Site logo

api-analytics's Issues

Example code should follow best practices

If we are providing this repo as an example of how to implement our analytics, we really need to follow best practices if we want to avoid support issues and ensure that our recommendations are credible. I don't feel it's sufficient to just have a sentence that says the code isn't optimal.

As examples:

  • onscroll and resize events should be debounced to avoid performance issues.
  • Is jQuery required? Why? Does it have to be loaded in the <head> of the document, blocking other resources? Performance-minded customers should resist this, and may resist jQuery itself, especially on mobile.
  • Do other script files need to be loaded in the <head>, blocking other resources? Performance-minded customers should resist this.
  • Some files are minified and some are not; is there a reason to provide a minified version of the tracker code here? Do we expect customers to host this code themselves or do we host it for them? If they are hosting it, they should minify it as part of their own process. This at least needs to be documented.

Include specific instructions on running the code

The instructions right now on how to run the code don't really give me a lot of help. It would be useful to provide specific instructions and, if required, specific examples of config files to support those instructions. For example, you could provide examples using python's simpleHTTPServer or Node's http-server.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.