ngx-google-places-autocomplete icon indicating copy to clipboard operation
ngx-google-places-autocomplete copied to clipboard

chore: angular 10 updates

Open NathanWalker opened this issue 4 years ago • 4 comments

NathanWalker avatar Aug 12 '20 01:08 NathanWalker

Should this branch work as is on Angular 10? The currently released version yields console warnings that it's a CommonJS dependency, so I was hoping this branch would remedy that, but this is all new to me. I tried: npm install --save NathanWalker/ngx-google-places-autocomplete#feat/angular-10

What should my imports be updated to? I currently have import { GooglePlaceModule } from 'ngx-google-places-autocomplete'; which yields:

TS2307: Cannot find module 'ngx-google-places-autocomplete' or its corresponding type declarations.

Is it just that types are missing? I see index.d.ts referenced but I don't see any declaration files. Any help appreciated.

ccondrup avatar Aug 27 '20 15:08 ccondrup

@ccondrup i'm having this warning too, it'd be great to convert all CommonJS modules to ECMAScript modules, since CommonJS obstructs tree-shaking of modules. @skynet2, is there any chance to fix this, sir?

IslombekHasan avatar Nov 12 '20 13:11 IslombekHasan

@skynet2 Any update on this? I would like to get the optimizations from removing the CommonJS modules and remove the warning from my build process.

rjfahl avatar Jan 26 '21 23:01 rjfahl

@skynet2 Any update on this? I would like to get the optimizations from removing the CommonJS modules and remove the warning from my build process.

I think the devs have changed the tsconfig.json and replaced the CommonJS module with es2017 module..

Check the last commit here https://github.com/skynet2/ngx-google-places-autocomplete/pull/64/commits/f7cd3f3dc0cf45d7a95b39db582ac2b9585a43d6

jaradehr1 avatar Jan 29 '21 17:01 jaradehr1