[ 
https://issues.apache.org/jira/browse/TINKERPOP-2137?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16750957#comment-16750957
 ] 

Dominik Franek commented on TINKERPOP-2137:
-------------------------------------------

So I've been working on the issue. I found out that WS package and Crypto 
package were outdated + they were intended to be used with server-side 
javascript only.

So in my fork [https://github.com/fdominik/tinkerpop/] I created 2 commits:

[bbf2c010e77cc4f68cdf8248cab124ff298361fd|https://github.com/fdominik/tinkerpop/commit/bbf2c010e77cc4f68cdf8248cab124ff298361fd],
 
[b016cd1bbd30cd0827812808c75abe51eb7a18ee|https://github.com/fdominik/tinkerpop/commit/b016cd1bbd30cd0827812808c75abe51eb7a18ee]
 These commits remove the require part and use standard Browser libraries.
 * For crypto package it is just generateRandomBytes.
 * For ws package it is more complicated as Browsers don't support the Options 
which might be required in server-side javascript (e.g. keyStore etc), so it 
might be a good idea to choose in the config whether the gremlin-javascript 
runs as client side or server side.

> Gremlin Javascript can't be used in Angular applications
> --------------------------------------------------------
>
>                 Key: TINKERPOP-2137
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-2137
>             Project: TinkerPop
>          Issue Type: Bug
>          Components: javascript
>    Affects Versions: 3.4.0
>         Environment: "@angular/cdk": "^7.2.1",
>            Reporter: Dominik Franek
>            Priority: Major
>
> If you try to install gremlin using
> {code:java}
> ng add gremlin{code}
> it gets you:
> _The package that you are trying to add does not support schematics. You can 
> try using a different version of the package or contact the package author to 
> add ng-add support._
> If you try using
> {code:java}
> npm i gremlin{code}
> it is installed, however the gremlin package can't be used in Angular 
> Application. Is there any way to fix it to work for ng-add? If not, maybe the 
> documentation needs an update of what Javascript environments are supported, 
> because our project intended to use Gremlin (we tried using Java, that 
> Gremlin is perfect... now when developing we found out that it is not 
> possible in Angular :) ).



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to