New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

aframe-lerp-component

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

aframe-lerp-component

A linear interpolation component for A-Frame.

  • 1.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
11
decreased by-56%
Maintainers
1
Weekly downloads
 
Created
Source

aframe-lerp-component

A linear interpolation component for A-Frame.

Changes the position, rotation, or scale when you call el.setAttribute('position', ...) from the current value to the new value in time duration.

Use directly by calling el.components.lerp.toPosition(from, to)

GIF Example

Try on Glitch: https://aframe-lerp-component.glitch.me/

API

PropertyDescriptionDefault Value
durationTime to move from from to to in milliseconds (ms)100
propertiesArray of properties to lerp. Eg. to only lerp position and rotation set to position, rotationposition, rotation, scale

Installation

Browser

Install and use by directly including the browser files:

<head>
  <title>My A-Frame Scene</title>
  <script src="https://aframe.io/releases/0.4.0/aframe.min.js"></script>
  <script src="https://unpkg.com/aframe-lerp-component/dist/aframe-lerp-component.min.js"></script>
</head>

<body>
  <a-scene>
    <a-entity lerp="duration: 100; properties: position, rotation, scale"></a-entity>
  </a-scene>
</body>
npm

Install via npm:

npm install aframe-lerp-component

Then require and use.

require('aframe');
require('aframe-lerp-component');

Keywords

FAQs

Package last updated on 30 Jul 2017

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc