![require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages](https://cdn.sanity.io/images/cgdhsj6q/production/be8ab80c8efa5907bc341c6fefe9aa20d239d890-1600x1097.png?w=400&fit=max&auto=format)
Security News
require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
vk-api-angular
Advanced tools
VK Open API wrapper for AngularJS.
You may initialize your VK application using the provider during the configuration phase:
angular.module('my-app', ['vk-api-angular'])
.config(function (VKApiProvider) {
VKApiProvider.init(10000); // Your VK APP_ID
});
VKApi factory duplicates the official VK Open API method naming, in particular:
VKApi.Api.call
VKApi.Auth.login
VKApi.Auth.logout
VKApi.Auth.revokeGrants
VKApi.Auth.getLoginStatus
VKApi.Auth.getSession
However, the promises are used instead of callbacks. This gives a better control over the success/error handling mechanism.
// Log in and request the "photos" and "video" permissions.
// See https://vk.com/dev/permissions for the full permission list.
VKApi.Auth.login({
photos: true,
video: true
}).then(
// Success:
function (response) {
var name = response.session.user.first_name;
alert('Hello, ' + name + '!');
},
// Error:
function (response) {
alert('Sorry, access denied.');
console.error(response);
}
);
// Call "users.get" API method.
// See https://vk.com/dev/methods for the full method list.
VKApi.Api.call('users.get').then(
// Success:
function (response) {
var name = response[0].first_name;
alert('Hello, ' + name + '!');
},
// Error:
function (response) {
alert('Sorry, could not fetch the user data.');
console.error(response);
}
);
<vk-allow-messages-from-community group-id="ID"></vk-allow-messages-from-community>
<vk-auth></vk-auth>
<vk-comments></vk-comments>
<vk-community group-id="ID"></vk-community>
<vk-community-messages group-id="ID"></vk-community-messages>
<vk-contact-us owner-id="ID"></vk-contact-us>
<vk-like></vk-like>
<vk-poll poll-id="POLL"></vk-poll>
<vk-post owner-id="ID" post-id="POST" hash="HASH"></vk-post>
<vk-recommended></vk-recommended>
<vk-share></vk-share>
<vk-subscribe owner-id="ID"></vk-subscribe>
1.2.0
FAQs
VK Open API AngularJS wrapper
The npm package vk-api-angular receives a total of 12 weekly downloads. As such, vk-api-angular popularity was classified as not popular.
We found that vk-api-angular demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.