Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
V
Vereign Client Library
Manage
Activity
Members
Labels
Plan
Issues
24
Issue boards
Milestones
Wiki
Code
Merge requests
5
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Code
Vereign Client Library
Merge requests
!4
Use webpack for bundling JS libs and move Golang code related to Iframe generation there
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Use webpack for bundling JS libs and move Golang code related to Iframe generation there
feature-vcl-webpack-bundle
into
master
Overview
0
Commits
36
Pipelines
0
Changes
17
Merged
Igor Markin
requested to merge
feature-vcl-webpack-bundle
into
master
6 years ago
Overview
0
Commits
36
Pipelines
0
Changes
1
Expand
0
0
Merge request reports
Viewing commit
2863feb3
Prev
Next
Show latest version
1 file
+
43
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
2863feb3
Add usage examples
· 2863feb3
Markin Igor
authored
6 years ago
README.md
+
43
−
0
Options
@@ -3,6 +3,49 @@
Vereign’s JavaScript library is an asynchronous library that allows for digitally signing your email and in-browser documents, data encryption, and key-based authentication.
## Usage
Add library as inline script.
```
html
<script
type=
"text/javascript"
src=
"./viamapi-client.js"
/>
```
Initialize library
```
js
// Target container used to append iframe
const
containerId
=
"
root
"
;
// Required methods used to be called within iframe.
const
methods
=
{
onEvent
(
event
)
{
console
.
log
(
event
)
}
};
// Iframe URL to connect
const
iframeUrl
=
"
https://test.org/iframe
"
;
// API url used to access endpoints
const
apiUrl
=
"
https://test.org/api
"
;
this
.
library
=
setupViamAPI
(
containerId
,
methods
,
iframeUrl
,
apiUrl
);
this
.
library
.
then
(
lib
=>
{
this
.
listenerUUID
=
this
.
addListener
({
callback
:
function
(
event
)
{
handleEvent
(
event
);
},
filters
:
[
"
IdentityNotLoaded
"
,
"
ActionConfirmedAndExecuted
"
,
"
Authenticated
"
]
});
lib
.
listIdentities
().
then
(
response
=>
{
this
.
setState
({
identities
:
response
.
data
});
});
});
```
## Development
### Running
Loading