Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bendc/animateplus
/ rgba
Function
rgba
animateplus.js:125–129 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
123
hexPairs(color).map(string => parseInt(string, 16));
124
125
const
rgba = hex => {
126
const
color = hex.slice(1);
127
const
[r, g, b, a] = convert(color);
128
return
`rgba(${r}, ${g}, ${b}, ${a / 255})`;
129
};
130
131
132
// easing equations
Callers
1
sanitize
Function · 0.85
Calls
1
convert
Function · 0.85
Tested by
no test coverage detected