Use with typescript
See original GitHub issueHello Thank you for this great lib I can not manage to use it in silex.me which is in typescript too Here is what i do
$ npm install --save-dev detect.js
Then in the code
import { detect } from 'detect-browser';
And the result is TS2307: Cannot find module 'detect-browser'.
I also tried installing the github repo with npm install --save-dev DamonOehlman/detect-browser
Here is another try:
ls -l node_modules/detect-browser
total 80K
drwxrwxr-x. 2 lexoyo lexoyo 4.0K May 31 17:25 .
drwxrwxr-x. 760 lexoyo lexoyo 24K May 31 17:29 ..
-rw-rw-r--. 1 lexoyo lexoyo 1.9K Oct 26 1985 index.d.ts
-rw-rw-r--. 1 lexoyo lexoyo 5.7K Oct 26 1985 index.js
-rw-rw-r--. 1 lexoyo lexoyo 1.1K Oct 26 1985 LICENSE
-rw-rw-r--. 1 lexoyo lexoyo 2.1K May 31 17:25 package.json
-rw-rw-r--. 1 lexoyo lexoyo 4.3K Oct 26 1985 README.md
-rw-rw-r--. 1 lexoyo lexoyo 19K Oct 26 1985 yarn.lock
Thank you in advance for any help
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Documentation - TypeScript for JavaScript Programmers
TypeScript knows the JavaScript language and will generate types for you in many cases. For example in creating a variable and assigning it...
Read more >What is TypeScript and why should you use it? - Contentful
TypeScript extends JavaScript and improves the developer experience. It enables developers to add type safety to their projects. Moreover, ...
Read more >How to Use TypeScript – Beginner-Friendly TS Tutorial
TypeScript is a superset of JavaScript. Superset means that it adds features on top of what JavaScript offers. TypeScript takes all the ...
Read more >Node.js with TypeScript
TypeScript is a trendy open-source language maintained and developed by Microsoft. It's loved and used by a lot of software developers around the...
Read more >Why You Should Use Typescript for Your Next Project
TypeScript is a superset of typed JavaScript (optional) that can help build and manage large-scale JavaScript projects. It can be considered ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I didn’t upgrade yet I will eventually Maybe we should close this issue and I’ll reopen it if doesn’t work
@lexoyo Just wondering if you had any success with
4.5.1
- looking to close this issue if you did.