diff --git a/lib/potassium/assets/app/javascript/api/index.ts b/lib/potassium/assets/app/javascript/api/index.ts index 9f44b872..31568334 100644 --- a/lib/potassium/assets/app/javascript/api/index.ts +++ b/lib/potassium/assets/app/javascript/api/index.ts @@ -12,6 +12,8 @@ const api = axios.create({ ], }); +export default api; + /* // Example to use the api object in the path ´app/javascript/api/users.ts´ diff --git a/lib/potassium/assets/tsconfig.json b/lib/potassium/assets/tsconfig.json index 532efa78..fa7ab6bf 100644 --- a/lib/potassium/assets/tsconfig.json +++ b/lib/potassium/assets/tsconfig.json @@ -26,6 +26,7 @@ "app/javascript/**/*.vue" ], "exclude": [ - "node_modules" + "node_modules", + "**/*.spec.ts" ] } diff --git a/lib/potassium/recipes/front_end.rb b/lib/potassium/recipes/front_end.rb index b226ff88..34417b4b 100644 --- a/lib/potassium/recipes/front_end.rb +++ b/lib/potassium/recipes/front_end.rb @@ -124,7 +124,7 @@ def setup_jest def setup_vue run "bin/yarn add vue@#{VUE_VERSION} vue-loader@#{VUE_LOADER_VERSION} "\ - "babel-preset-typescript-vue3" + "babel-preset-typescript-vue3 @types/humps" run "bin/yarn add vue-tsc --dev" gsub_file( 'config/webpack/webpack.config.js',