<p>I thought I have to <code>import 'rust-lib'</code> but instead I have to</p>
<pre><code>import CardanoWasm = require('@emurgo/cardano-serialization-lib-nodejs')
</code></pre>
<p>Get the idea from <a href="https://cardano.stackexchange.com/questions/8936/how-to-get-publickey-from-privatekey">this answer</a>.</p>

CC BY-SA 4.0
2022-12-10T05:46:56.317Z
2022-12-10T05:46:56.317Z
Adam
<p>I follow <a href="https://developers.cardano.org/docs/get-started/cardano-serialization-lib/overview" rel="nofollow noreferrer">this guide</a> to get start with cardano-serialization-lib.
Install nodejs package with:</p>
<pre><code>npm i @emurgo/cardano-serialization-lib-nodejs
</code></pre>
<p>Still can't get it running. The module 'rust-lib' can't be found. And of course when try to <code>import 'rust-lib'</code> there is an error:</p>
<pre><code>error TS2307: Cannot find module 'rust-lib' or its corresponding type declarations.
</code></pre>
<p>So how do I get the module visible?</p>
<p>Step-by-step guide would be really appreciated. I don't have very deep knowledge about how nodejs or rust works.</p>

<cardano-serialization-lib><emurgo>
How to install/use cardano-serialization-lib
# How to install/use cardano-serialization-lib

(Asked by: username_0 on 2022-12-10)

I follow this guide to get start with cardano-serialization-lib.
Install nodejs package with:
npm i @emurgo/cardano-serialization-lib-nodejs

Still can't get it running. The module 'rust-lib' can't be found. And of course when try to import 'rust-lib' there is an error:
error TS2307: Cannot find module 'rust-lib' or its corresponding type declarations.

So how do I get the module visible?
Step-by-step guide would be really appreciated. I don't have very deep knowledge about how nodejs or rust works.

**Tags:** cardano-serialization-lib, emurgo

---

## 1 answers

### Answer by username_0 on 2022-12-10. Score: 1

I thought I have to import 'rust-lib' but instead I have to
import CardanoWasm = require('@emurgo/cardano-serialization-lib-nodejs')

Get the idea from this answer.


---

