Giter Club home page Giter Club logo

meteor-accounts-vk's Introduction

meteor-accounts-vk

Login service for VKontakte accounts (https://vk.com).

Usage

  1. Add the package to your project using meteorite:
$ meteor add mrt:accounts-vk
  1. Configure vkontakte login service. You can do mannually or using GUI.

    Manually: Just add next code to your config file.

        if (Meteor.isServer) {
            ServiceConfiguration.configurations.remove({
                service: 'vk'
            });
    
            ServiceConfiguration.configurations.insert({
                service: 'vk',
                appId:   '1234567',       // Your app id
                secret:  'someappsecret', // Your app secret
                scope:   'email,status'   // Your app scope
            });
        }

    GUI:

    • Add accounts-ui package to your project:

      $ meteor add accounts-ui
    • Set {{> loginButtons}} into your template

    • Go to your browser, open page with {{> loginButtons}}

    • Click on "configure Vk login" button

    • Fill "App Id", "App Secret", "Scope" fields in popup window following by instructions

  2. Use Meteor.loginWithVk(options, callback) for user authentication (you can omit options argument).

  3. For customization of new user creation you must set 'createUser' event handler:

    if (Meteor.isServer) {
        Accounts.onCreateUser(function(options, user) {
            user.custom_field = "custom value";
            // ...
            return user;
        });
    }

Enjoy!

If this package helped you - STAR it on github. This is not difficult for you, but important for me.

Contributors

Thanks to these people for their contributions! I appriciate it a lot!

  • @mike1pol (Mikhail Poluboyarinov)
  • @Neftedollar
  • @illfantasy

Dependencies

  1. accounts-base
  2. accounts-oauth
  3. accounts-ui (if you want to use GUI)

githalytics.com alpha

Bitdeli Badge

meteor-accounts-vk's People

Contributors

amaygurov avatar bitdeli-chef avatar davidyuk avatar ivan133 avatar klimmalgin avatar mike1pol avatar neftedollar avatar

Watchers

 avatar

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.