Coder Social home page Coder Social logo

spring-boot's Introduction

spring-boot

springboot学习历程

Spring MVC

注解

RequestMapping和GetMapping区别

GetMapping等价于RequestMapping(method=RequestMethod=GET),同理还有PostMapping、PutMapping

RestController和Controller区别

前者多了个ResponseBody,将数据写入reponse的body中,转为json

RequestBody

请求参数在request的body中,一般为具体的对象

Vue

常用指令

1. v-bind

  • 变量绑定
  • v-bind:value="msg"等价于:value="msg"

2. v-on

  • 事件绑定
  • v-on:click="show"等价于@click="show"
  • show为methods中的方法函数

3. v-model

  • 双向绑定,同时改变
  • <input type="text" v-model="msg">

4. v-for

  • 循环遍历
  • <p v-for="item, i in list" :key="item.id">索引:{{i}} --- 值:{{item}}</p>
  • :key必须加上

5. v-show和v-if

  • 条件判断
  • <h3 v-if="flag">这是v-if控制的元素</h3>

6. Vue.componet

  • 模板

  • //js
    <script>
    // 定义名为 todo-item 的新组件
    Vue.component('todo-item', {
      template: '<li>这是个待办项</li>'
    })
    var app = new Vue(...)
    </script>
    
    //html
    <ol>
      <!-- 创建一个 todo-item 组件的实例 -->
      <todo-item></todo-item>
    </ol>

7. filter

  • 全局过滤 Vue.filter('过滤器名称', function(){})

  • 私有过滤

    new Vue()({
    	filters: {
    		过滤器名称: function(){}
    	}
    })

8. 自定义按键

  • @keyup.按键别名 = "要调用的方法名"
  • <input type="text" @keyup.enter="open">

其他

浏览器发送GET请求情况

  • 直接在地址栏中输入地址
  • 点击链接
  • 表单默认提交方式

浏览器发送POST请求情况

  • 将表单的method设置为post

spring-boot's People

Contributors

rookiezq avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.