You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am developing a service using spring boot + vuejs.
I'm so embarrassed that the function that worked well during the development test locally is not working if it is distributed after build.
I need your help.
Strangely, functions written in js code (which is a function that calls API that pokes api with a postmapping call and adds) The function works normally when running with npm run dev.
After npm run build, the dist file below was attached to the execution path and run build was executed.
The screen lookup part is normal, but the postmapping API call function has no response. I added an alert to debug the function when it runs
If you call the validation() method, which is the function, there is no result after the post call, and it seems that the call does not go to the DB.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello
I am developing a service using spring boot + vuejs.
I'm so embarrassed that the function that worked well during the development test locally is not working if it is distributed after build.
I need your help.
The package.json is as follows.
{ "name": "frontend", "version": "0.0.0", "private": "true", "scripts": { "dev": "vite", "build": "vite build", "preview": "vite preview", "lint": "eslint ./src/*.{js,ts,jsx,tsx,html,vue}", "lint-f": "eslint --fix ./src/*.{js,ts,jsx,tsx,html,vue}", "yarn": "node node_modules/yarn/bin/yarn.js" }, "dependencies": { "axios": "^0.27.2", "daisyui": "^2.14.2", "dayjs": "^1.11.2", "vue": "^3.2.25", "vue-axios": "^3.4.1", "vue-router": "^4.0.14", "vue-tsc": "^0.34.10", "vuex": "^4.0.2" }, "devDependencies": { "@typescript-eslint/eslint-plugin": "^5.21.0", "@typescript-eslint/parser": "^5.21.0", "@vitejs/plugin-vue": "^2.3.1", "autoprefixer": "^10.4.7", "eslint": "^8.14.0", "postcss": "^8.4.12", "postcss-cli": "^9.1.0", "tailwindcss": "^3.0.24", "typescript": "^4.6.4", "vite": "^2.9.15" } }
Strangely, functions written in js code (which is a function that calls API that pokes api with a postmapping call and adds) The function works normally when running with npm run dev.
After npm run build, the dist file below was attached to the execution path and run build was executed.
The screen lookup part is normal, but the postmapping API call function has no response. I added an alert to debug the function when it runs
If you call the validation() method, which is the function, there is no result after the post call, and it seems that the call does not go to the DB.
Below is the script part of the component.
`
import http from "../../http-common";
export default {
name: "addGameDataVersion",
data() {
return {
form: '',
id: '',
gamedataName: '',
artifactId: '',
gameCode: '',
port: '',
nodePort: '',
prefixApi: ''
},
watch: {
gamedataName(val) {
const reg = /[ㄱ-ㅎ|ㅏ-ㅣ|가-힣]/;
},
methods: {
async validation() {
}
}
`
If you know the cause of such an issue, please give me. Help me.
Beta Was this translation helpful? Give feedback.
All reactions