{"id":10981,"date":"2022-11-21T07:00:36","date_gmt":"2022-11-20T22:00:36","guid":{"rendered":"https:\/\/blog.capilano-fw.com\/?p=10981"},"modified":"2023-01-17T18:29:53","modified_gmt":"2023-01-17T09:29:53","slug":"laravel-react-%e3%81%a7%e3%83%af%e3%83%b3%e3%82%af%e3%83%aa%e3%83%83%e3%82%af%e3%81%a7%e3%82%af%e3%83%aa%e3%82%a2%e3%81%a7%e3%81%8d%e3%82%8b%e5%85%a5%e5%8a%9b%e3%83%9c%e3%83%83%e3%82%af%e3%82%b9","status":"publish","type":"post","link":"https:\/\/blog.capilano-fw.com\/?p=10981","title":{"rendered":"Laravel + React \u3067\u30ef\u30f3\u30af\u30ea\u30c3\u30af\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u5165\u529b\u30dc\u30c3\u30af\u30b9\u3092\u3064\u304f\u308b"},"content":{"rendered":"<p>\u3055\u3066\u3055\u3066\u3001\u3053\u3053\u6700\u8fd1\u306f<code>React<\/code>\u306e\u9762\u767d\u3055\u306b\u89e6\u308c\u3066\u3057\u307e\u3063\u3066\u3001\u305a\u3063\u3068<code>React<\/code>\u95a2\u9023\u306e\u8a18\u4e8b\u304c\u7d9a\u3044\u3066\u3044\u307e\u3059\u3002\uff08\u521d\u3081\u3066\u30b3\u30ed\u30b3\u30ed\u6383\u9664\u3092\u3057\u305f\u3068\u304d\u6b62\u307e\u3089\u306a\u304f\u306a\u3063\u305f\u611f\u899a\u306b\u4f3c\u3066\u307e\u3059\ud83d\udc4d\uff09<\/p>\n<p>\u3068\u3044\u3046\u3053\u3068\u3067\u3001\u4ed6\u306b\u3082\u4f55\u304b\u30e6\u30fc\u30b6\u30d3\u30ea\u30c6\u30a3\u95a2\u9023\u3067\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304c\u4f5c\u308c\u306a\u3044\u304b\u306a\u3068\u8003\u3048\u3066\u3044\u305f\u3068\u3053\u308d\u3001\u5730\u5473\u306b\u4fbf\u5229\u306a\u3082\u306e\u3092\u601d\u3044\u51fa\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u308c\u306f\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><strong style=\"font-size: 35px;\">\u30ef\u30f3\u30af\u30ea\u30c3\u30af\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u5165\u529b\u30dc\u30c3\u30af\u30b9<\/strong><\/p>\n<p>\u3067\u3059\u3002\u4f8b\u3048\u3070\u3053\u3093\u306a\u30ab\u30f3\u30b8\u3067\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10998\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_1.png\" alt=\"\" width=\"283\" height=\"57\" \/><\/p>\n<p>\u3064\u307e\u308a\u3001\u901a\u5e38\u306e<code>&lt;input&gt;<\/code>\u3067\u306f\u3001\u6587\u5b57\u3092\u524a\u9664\u3059\u308b\u3068\u304d\u30d0\u30c3\u30af\u30b9\u30da\u30fc\u30b9\u3067\uff11\u6587\u5b57\u305a\u3064\u6d88\u3059\u304b\u3001\u5168\u4f53\u3092\u9078\u629e\u72b6\u614b\u306b\u3057\u3066\u524a\u9664\u3057\u306a\u3044\u3068\u5168\u30af\u30ea\u30a2\u306b\u306f\u306a\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u3082\u3057\u30b9\u30d4\u30fc\u30c9\u3092\u6c42\u3081\u3089\u308c\u308b\u73fe\u5834\u3067\u306e\u5165\u529b\u30dc\u30c3\u30af\u30b9\u3060\u3063\u305f\u3068\u3057\u305f\u3089\u5168\u30af\u30ea\u30a2\u304c\u3042\u308b\u3068\u4fbf\u5229\u3067\u3059\u3088\u306d\u3002<\/p>\n<p>\u305d\u3053\u3067\u2757<\/p>\n<p>\u4eca\u56de\u306f\u3001<code>Laravel + React<\/code>\u3067\u300c<strong>\u30ef\u30f3\u30af\u30ea\u30c3\u30af\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u5165\u529b\u30dc\u30c3\u30af\u30b9<\/strong>\u300d\u3092\u4f5c\u3063\u3066\u307f\u307e\u3059\u3002<\/p>\n<p>\u305c\u3072\u4f55\u304b\u306e\u53c2\u8003\u306b\u306a\u308a\u307e\u3057\u305f\u3089\u5b09\u3057\u3044\u3067\u3059\u3002\ud83d\ude04\u2728<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-3405 aligncenter\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/04\/no_18.png\" alt=\"\" width=\"310\" height=\"320\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/04\/no_18.png 310w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/04\/no_18-291x300.png 291w\" sizes=\"auto, (max-width: 310px) 100vw, 310px\" \/>\u300c\u540d\u66f2\u30a4\u30fc\u30b8\u30e5\u30fc\u2605\u30e9\u30a4\u30c0\u30fc\u306f\u3001<br \/>\n\u3082\u3046\u65c5\u733f\u30d0\u30fc\u30b8\u30e7\u30f3\u3067\u3057\u304b<br \/>\n\u8133\u5185\u518d\u751f\u3055\u308c\u307e\u305b\u3093\ud83d\ude07\u300d<\/p>\n<p><strong>\u958b\u767a\u74b0\u5883\uff1a<\/strong> Laravel 9.x\u3001React\u3001Vite\u3001Inertia.js\u3001TailwindCSS<\/p>\n<h1>Font Awesome \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b<\/h1>\n<p>\u307e\u305a\u3001\u4eca\u56de\u306f\u30af\u30ea\u30a2\u30dc\u30bf\u30f3\u306b\u4ee5\u4e0b\u306e\u30a2\u30a4\u30b3\u30f3\u30d5\u30a9\u30f3\u30c8\u3092\u4f7f\u3044\u305f\u3044\u306e\u3067\u3001\u5148\u306b<code>Font Awesome<\/code>\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u304a\u304d\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-11000\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_7.png\" alt=\"\" width=\"30\" height=\"30\" \/><\/p>\n<p>\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3067\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<pre><strong>npm i font-awesome --save<\/strong><\/pre>\n<p>\u305d\u3057\u3066\u3001<code>Vite<\/code>\u304c\u30a2\u30af\u30bb\u30b9\u3067\u304d\u308b\u3088\u3046\u306b<code>font-awesome<\/code>\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002<\/p>\n<p><strong>resources\/css\/app.css<\/strong><\/p>\n<pre><strong>@import 'font-awesome\/css\/font-awesome.css';<\/strong>\r\n\r\n@tailwind base;\r\n@tailwind components;\r\n@tailwind utilities;<\/pre>\n<p><strong>\u3010\u3054\u6ce8\u610f\u2757\u3011<br \/>\n<\/strong>\u3069\u3046\u3084\u3089<code>@import<\/code>\u306f\u4e00\u756a\u6700\u521d\u306b\u66f8\u304b\u306a\u3051\u308c\u3070\u3044\u3051\u306a\u3044\u3089\u3057\u304f\u3001\u3082\u3057<code>@tailwind<\/code>\u306e\u5f8c\u306b\u8ffd\u52a0\u3057\u3066\u3057\u307e\u3046\u3068\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3057\u307e\u3044\u307e\u3059\u3002<br \/>\n\u304a\u6c17\u3092\u3064\u3051\u304f\u3060\u3055\u3044\u3002m(_ _)m<\/p>\n<h1>\u30eb\u30fc\u30c8\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u7d9a\u3044\u3066\u30eb\u30fc\u30c8\u3092\u3064\u304f\u308a\u307e\u3059\u3002<br \/>\n\u4eca\u56de\u306f\u3072\u3068\u3064\u3060\u3051\u3067OK\u3067\u3059\u3002<\/p>\n<p><strong>routes\/web.php<\/strong><\/p>\n<pre><strong>use Inertia\\Inertia;<\/strong>\r\n\r\n\/\/ \u7701\u7565\r\n\r\n<strong>Route::get('clear_input', fn() =&gt; Inertia::render('ClearInput\/Index'));<\/strong><\/pre>\n<p>\u203b \u672c\u6765\u306f\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u3064\u304f\u308b\u65b9\u304c\u3044\u3044\u3068\u601d\u3044\u307e\u3059\u304c\u3001\u30c6\u30b9\u30c8\u306a\u306e\u3067\u7701\u7565\u5f62\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<h1>\u30d3\u30e5\u30fc\u3092\u3064\u304f\u308b<\/h1>\n<p>\u6b21\u306b\u30d6\u30e9\u30a6\u30b6\u304b\u3089\u5b9f\u969b\u306b\u30a2\u30af\u30bb\u30b9\u3055\u308c\u308b\u3053\u3068\u306b\u306a\u308b\u30d3\u30e5\u30fc\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u306a\u304a\u3001\u4eca\u56de\u306f\u6b21\u306e\u9805\u76ee\u3067\u3064\u304f\u308b<code>ClearInput<\/code>\u3092\uff13\u3064\u8a2d\u7f6e\u3057\u3066\u3061\u3083\u3093\u3068\u533a\u5225\u3067\u304d\u308b\u304b\u30c1\u30a7\u30c3\u30af\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n<p><strong>resources\/js\/Pages\/ClearInput\/Index.jsx<\/strong><\/p>\n<pre><strong>import {useState, useEffect} from 'react';<\/strong>\r\n<strong>import ClearInput from '@\/Components\/ClearInput';<\/strong>\r\n\r\n<strong>export default function Index() {<\/strong>\r\n\r\n<strong>    \/\/ Data<\/strong>\r\n<strong>    const [value1, setValue1] = useState('');<\/strong>\r\n<strong>    const [value2, setValue2] = useState('');<\/strong>\r\n<strong>    const [value3, setValue3] = useState('\u521d\u671f\u5024\u3042\u308a');<\/strong>\r\n\r\n<strong>    \/\/ Effect<\/strong>\r\n<strong>    useEffect(() =&gt; {<\/strong>\r\n\r\n<strong>        console.log('--------------------------------');<\/strong>\r\n<strong>        console.log(`value1 \u2192 ${value1}`);<\/strong>\r\n<strong>        console.log(`value2 \u2192 ${value2}`);<\/strong>\r\n<strong>        console.log(`value3 \u2192 ${value3}`);<\/strong>\r\n\r\n<strong>    }, [value1, value2, value3]);<\/strong>\r\n\r\n<strong>    return (<\/strong>\r\n<strong>        &lt;div className=\"p-4\"&gt;<\/strong>\r\n<strong>            &lt;h1 className=\"font-bold mb-3\"&gt;&amp;#x1F4DD; React\uff1a \u30ef\u30f3\u30af\u30ea\u30c3\u30af\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u5165\u529b\u30dc\u30c3\u30af\u30b9&lt;\/h1&gt;<\/strong>\r\n\r\n<strong>            &lt;div className=\"mb-3 w-64\"&gt;<\/strong>\r\n<strong>                &lt;ClearInput value={value1} onChange={value =&gt; setValue1(value)} \/&gt;<\/strong>\r\n<strong>            &lt;\/div&gt;<\/strong>\r\n<strong>            &lt;div className=\"mb-3 w-64\"&gt;<\/strong>\r\n<strong>                &lt;ClearInput value={value2} onChange={value =&gt; setValue2(value)} \/&gt;<\/strong>\r\n<strong>            &lt;\/div&gt;<\/strong>\r\n<strong>            &lt;div className=\"mb-3 w-64\"&gt;<\/strong>\r\n<strong>                &lt;ClearInput value={value3} onChange={value =&gt; setValue3(value)} \/&gt;<\/strong>\r\n<strong>            &lt;\/div&gt;<\/strong>\r\n\r\n<strong>        &lt;\/div&gt;<\/strong>\r\n<strong>    );<\/strong>\r\n<strong>}<\/strong><\/pre>\n<h1>\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u4eca\u56de\u306e\u30e1\u30a4\u30f3\u306e\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u300c<strong>ClearInput<\/strong>\u300d\u3067\u3059\u3002<\/p>\n<p><strong>resources\/js\/Components\/ClearInput.jsx<\/strong><\/p>\n<pre><strong>import {useState, useRef, useEffect} from 'react';<\/strong>\r\n\r\n<strong>export default function ClearInput(props) {<\/strong>\r\n\r\n<strong>    \/\/ \u5165\u529b\u30dc\u30c3\u30af\u30b9<\/strong>\r\n<strong>    const inputRef = useRef();<\/strong>\r\n<strong>    const [value, setValue] = useState(props.value || '');<\/strong>\r\n<strong>    useEffect(() =&gt; { \/\/ value \u304c\u5909\u5316\u3057\u305f\u3089\u5b9f\u884c\u3055\u308c\u308b<\/strong>\r\n\r\n<strong>        const icon = iconRef.current;<\/strong>\r\n\r\n<strong>        \/\/ \u30af\u30ea\u30a2\u30dc\u30bf\u30f3\u306e\u8868\u793a\u30fb\u975e\u8868\u793a<\/strong>\r\n<strong>        if(value.length &gt; 0) {<\/strong>\r\n\r\n<strong>            icon.classList.remove('invisible');<\/strong>\r\n\r\n<strong>        } else {<\/strong>\r\n\r\n<strong>            icon.classList.add('invisible');<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n\r\n<strong>        if(typeof props.onChange === 'function') { \/\/ \u89aa\u8981\u7d20\u306b onChange \u304c\u3042\u308c\u3070\u5b9f\u884c\u3059\u308b<\/strong>\r\n\r\n<strong>            props.onChange(value);<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n\r\n<strong>    }, [value]);<\/strong>\r\n\r\n<strong>    \/\/ \u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3<\/strong>\r\n<strong>    const iconRef = useRef();<\/strong>\r\n<strong>    const handleIconClick = () =&gt; { \/\/ \u30a2\u30a4\u30b3\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u305f\u3089\u5b9f\u884c\u3055\u308c\u308b<\/strong>\r\n\r\n<strong>        setValue('');<\/strong>\r\n<strong>        inputRef.current.focus();<\/strong>\r\n\r\n<strong>    };<\/strong>\r\n<strong>    const setIconPosition = () =&gt; { \/\/ \u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3\u306e\u4f4d\u7f6e\u3092\u8abf\u6574\u3059\u308b<\/strong>\r\n\r\n<strong>        const input = inputRef.current;<\/strong>\r\n<strong>        const icon = iconRef.current;<\/strong>\r\n\r\n<strong>        if(input &amp;&amp; icon) {<\/strong>\r\n\r\n<strong>            const inputHeight = input.clientHeight;<\/strong>\r\n<strong>            const iconHeight = icon.clientHeight;<\/strong>\r\n<strong>            const iconTop = (inputHeight - iconHeight) \/ 2;<\/strong>\r\n\r\n<strong>            icon.style.top = iconTop +'px';<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n\r\n<strong>    };<\/strong>\r\n<strong>    useEffect(() =&gt; { \/\/ \u30da\u30fc\u30b8\u304c\u8aad\u307f\u8fbc\u307e\u308c\u305f\u3089\u5b9f\u884c\u3055\u308c\u308b<\/strong>\r\n\r\n<strong>        setIconPosition();<\/strong>\r\n\r\n<strong>    }, []);<\/strong>\r\n\r\n<strong>    return (<\/strong>\r\n<strong>        &lt;div className=\"relative\"&gt;<\/strong>\r\n\r\n<strong>            {\/* \u5165\u529b\u30dc\u30c3\u30af\u30b9 *\/}<\/strong>\r\n<strong>            &lt;input<\/strong>\r\n<strong>                value={value}<\/strong>\r\n<strong>                ref={inputRef}<\/strong>\r\n<strong>                className=\"w-full px-1.5 py-1 border border-gray-300 text-gray-900\"<\/strong>\r\n<strong>                onChange={e =&gt; setValue(e.target.value)} \/&gt;<\/strong>\r\n\r\n<strong>            {\/* \u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3 *\/}<\/strong>\r\n<strong>            &lt;a<\/strong>\r\n<strong>                href=\"#\"<\/strong>\r\n<strong>                ref={iconRef}<\/strong>\r\n<strong>                tabIndex=\"-1\"<\/strong>\r\n<strong>                className=\"absolute right-2.5 invisible\"<\/strong>\r\n<strong>                onClick={e =&gt; handleIconClick(e)}&gt;<\/strong>\r\n<strong>                &lt;i className=\"fa fa-times-circle\"&gt;&lt;\/i&gt;<\/strong>\r\n<strong>            &lt;\/a&gt;<\/strong>\r\n\r\n<strong>        &lt;\/div&gt;<\/strong>\r\n<strong>    );<\/strong>\r\n\r\n<strong>}<\/strong><\/pre>\n<p>\u3067\u306f\u3001\u3053\u306e\u4e2d\u3067\u3084\u3063\u3066\u3044\u308b\u3053\u3068\u3092\u3072\u3068\u3064\u305a\u3064\u898b\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u2757<\/p>\n<p><strong>\u3010\u8ffd\u8a18\uff1a2023.1.17\u3011<\/strong>\u30b3\u30fc\u30c9\u304c\u9593\u9055\u3063\u3066\u3044\u305f\u306e\u3067\u4fee\u6b63\u3057\u307e\u3057\u305f\u3002\u3054\u4e0d\u4fbf\u304a\u304b\u3051\u3057\u3066\u30b9\u30df\u30de\u30bb\u30f3\uff01<\/p>\n<h2>\u30b3\u30fc\u30c9\u5168\u4f53<\/h2>\n<p>\u307e\u305a\u30b3\u30fc\u30c9\u5168\u4f53\u306e\u69cb\u6210\u3067\u3059\u304c\u3001\u3053\u308c\u307e\u3067\u306f<code>Vue<\/code>\u3067\u8a00\u3046\u3068\u3053\u308d\u306e\u300c<strong>Options API<\/strong>\u300d\u306e\u3088\u3046\u306b\u300c<strong>\u5909\u6570\u306f\u5909\u6570\u3067\u307e\u3068\u3081\u3066\u66f8\u304f<\/strong>\u300d\u300c<strong>\u30e1\u30bd\u30c3\u30c9\u306f\u30e1\u30bd\u30c3\u30c9\u3067\u2026<\/strong>\u300d\u3068\u3044\u3046\u3088\u3046\u306a\u30b0\u30eb\u30fc\u30d7\u5206\u3051\u3092\u3057\u3066\u66f8\u3044\u3066\u3044\u307e\u3057\u305f\u304c\u3001\u4eca\u56de\u306f<code>Vue 3<\/code>\u3067\u5c0e\u5165\u3055\u308c\u305f\u300c<strong>Composition API<\/strong>\u300d\u306e\u3088\u3046\u306b\u300c\u5f79\u5272\u300d\u3067\u30b0\u30eb\u30fc\u30d7\u5206\u3051\u3092\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e\u305f\u3081\u3001\u4eca\u56de\u306e\u69cb\u9020\u3068\u3057\u3066\u306f\u5927\u304d\u304f\u300c<strong>\u5165\u529b\u30dc\u30c3\u30af\u30b9<\/strong>\u300d\u3068\u300c<strong>\u9589\u3058\u308b\u30dc\u30bf\u30f3<\/strong>\u300d\u306e\uff12\u30d6\u30ed\u30c3\u30af\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<h2>\u5165\u529b\u30dc\u30c3\u30af\u30b9<\/h2>\n<p>\u3053\u3053\u3067\u306f\u4e3b\u306b\u30af\u30ea\u30c3\u30af\u3059\u308b\u3068\u5165\u529b\u5185\u5bb9\u304c\u6d88\u3048\u308b\u300c<strong>\u5168\u524a\u9664\u30dc\u30bf\u30f3<\/strong>\u300d\u8868\u793a\uff0f\u975e\u8868\u793a\u3092\u5207\u308a\u66ff\u3048\u308b\u305f\u3081\u306b\u7528\u610f\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u307e\u305a<code>useRef()<\/code>\u3092\u4f7f\u3063\u3066<code>&lt;input&gt;<\/code>\u306b\u7c21\u5358\u306b\u30a2\u30af\u30bb\u30b9\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u3057\u3066\u3001\u305d\u306e\u5165\u529b\u30dc\u30c3\u30af\u30b9\u306b\u30d0\u30a4\u30f3\u30c7\u30a3\u30f3\u30b0\u3059\u308b\u5909\u6570\u306f<code>value<\/code>\u3067\u3059\u3002<\/p>\n<p>\u306a\u304a\u3001\u521d\u671f\u5024\u3092\u30bb\u30c3\u30c8\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u3066\u304a\u304d\u305f\u3044\u306e\u3067\u3001\u3082\u3057\u89aa\u8981\u7d20\u304b\u3089\u30c7\u30fc\u30bf\u9001\u4fe1\u3055\u308c\u3066\u3044\u308c\u3070\u305d\u308c\u3092\u4f7f\u3044\u3001\u306a\u3051\u308c\u3070\u7a7a\u767d\u304c\u9069\u7528\u3055\u308c\u308b\u3088\u3046\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre>useState(<strong>props.value || ''<\/strong>);<\/pre>\n<p>\u305d\u3057\u3066\u3001<code>useEffect()<\/code>\u306e\u4e2d\u8eab\u3067\u3059\u304c\u3001\u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3\u306e\u8868\u793a\uff0f\u975e\u8868\u793a\u3059\u308b\u6761\u4ef6\u306f\u4ee5\u4e0b\u306e\u3068\u304a\u308a\u3067\u3059\u3002<\/p>\n<ul>\n<li>\u4f55\u304b\u6587\u5b57\u304c\u5165\u529b\u3055\u308c\u3066\u3044\u308b \u2192 \u8868\u793a<\/li>\n<li>\u4f55\u3082\u5165\u529b\u304c\u306a\u3044 \u2192 \u8868\u793a\u3057\u306a\u3044<\/li>\n<\/ul>\n<p>\u305d\u306e\u305f\u3081\u3001<code>useEffect()<\/code>\u5185\u3067\u306f\u3001<code>value<\/code>\u306e\u4e2d\u8eab\u304c\u5909\u5316\u3057\u305f\u3068\u304d\u306b\u5b9f\u884c\u3055\u308c\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002\uff08\u7b2c\uff12\u5f15\u6570\u306e<code>[value]<\/code>\u306e\u90e8\u5206\u3067\u3069\u306e\u5024\u304c\u5909\u5316\u3059\u308b\u306e\u3092\u76e3\u8996\u3059\u308b\u304b\u6307\u5b9a\u3067\u304d\u307e\u3059\uff09<\/p>\n<h2>\u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3<\/h2>\n<p>\u30af\u30ea\u30c3\u30af\u3057\u305f\u3068\u304d\u306b\u5165\u529b\u5185\u5bb9\u3092\u3059\u3079\u3066\u524a\u9664\u3059\u308b\u6a5f\u80fd\u3067\u3059\u3002<\/p>\n<p>\u307e\u305a\u3053\u3053\u3067\u3082<code>useRef()<\/code>\u3092\u4f7f\u3063\u3066\u30a2\u30a4\u30b3\u30f3\u90e8\u5206\u306b\u30a2\u30af\u30bb\u30b9\u3057\u3084\u3059\u3044\u3088\u3046\u306b\u3057\u3001\u3055\u3089\u306b\u30af\u30ea\u30c3\u30af\u3055\u308c\u305f\u3089<code>setValue()<\/code>\u3092\u4f7f\u3063\u3066\u5165\u529b\u5185\u5bb9\u3092\u30af\u30ea\u30a2\u3057\u307e\u3059\u3002<\/p>\n<p>\u307e\u305f\u3001\u3053\u3053\u304c\u5c11\u3057\u3060\u3051\u8907\u96d1\u3067\u3059\u304c\u3001<code>setIconPosition()<\/code>\u306f\u300c<strong>\u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3<\/strong>\u300d\u306e\u4e0a\u4e0b\u4f4d\u7f6e\u304c\u771f\u3093\u4e2d\u306b\u304f\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3068\u3044\u3046\u306e\u3082\u3001\u4eca\u56de\u306f\u5165\u529b\u30dc\u30c3\u30af\u30b9\u306e\u5927\u304d\u3055\uff08\u9ad8\u3055\uff09\u306f\u56fa\u5b9a\u306a\u306e\u3067\u3001\u30b9\u30bf\u30a4\u30eb\u30b7\u30fc\u30c8\u3067<code>top:10px<\/code>\u3068\u3044\u3046\u3088\u3046\u306b\u6307\u5b9a\u3057\u3066\u3082\u554f\u984c\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u4eca\u5f8c\u9ad8\u3055\u304c\u5909\u308f\u308b\u3053\u3068\u3082\u60f3\u5b9a\u3055\u308c\u307e\u3059\uff08<code>sm<\/code>, <code>md<\/code>, <code>lg<\/code>\u306a\u3069\u30b5\u30a4\u30ba\u6307\u5b9a\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u3059\u308b\u3001\u305d\u3082\u305d\u3082<code>className<\/code>\u3092\u5909\u66f4\u3067\u304d\u308b\u3088\u3046\u306b\u3059\u308b\uff09\u306e\u3067\u3001\u305d\u308c\u3092\u60f3\u5b9a\u3057\u3066\u300c<strong>\u3069\u3093\u306a\u9ad8\u3055\u306b\u306a\u3063\u3066\u3082\u81ea\u52d5\u7684\u306b\u8a08\u7b97\u3057\u3066\u771f\u3093\u4e2d\u306b\u8868\u793a\u3055\u308c\u308b<\/strong>\u300d\u3088\u3046\u306b\u3057\u3066\u3044\u308b\u3068\u3044\u3046\u308f\u3051\u3067\u3059\ud83d\ude04<\/p>\n<p>\uff08\u3082\u3057\u304b\u3057\u3066\u30e2\u30c0\u30f3\u306aCSS\u306a\u3089\u5bfe\u5fdc\u3067\u304d\u307e\u3059\u304b\u306d\u2026\ud83e\udd14\uff09<\/p>\n<p>\u306a\u304a\u3001\u9589\u3058\u308b\u30a2\u30a4\u30b3\u30f3\u306e<code>&lt;a&gt;<\/code>\u30bf\u30b0\u306b\u306f\u3001<\/p>\n<pre><strong>tabIndex=\"-1\"<\/strong><\/pre>\n<p>\u304c\u3064\u3044\u3066\u3044\u307e\u3059\u304c\u3001\u3053\u308c\u306f\u30bf\u30d6\u30ad\u30fc\u3092\u62bc\u3057\u305f\u3068\u304d\u306b\u30d5\u30a9\u30fc\u30ab\u30b9\u304c\u5f53\u305f\u3063\u3066\u3057\u307e\u3046\uff08\uff1d\u6b21\u306e\u5165\u529b\u30dc\u30c3\u30af\u30b9\u306b\u98db\u3079\u306a\u3044\uff09\u306e\u3092\u9632\u6b62\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<h1>\u30c6\u30b9\u30c8\u3057\u3066\u307f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u5b9f\u969b\u306b\u30c6\u30b9\u30c8\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u2757<\/p>\n<p>\u307e\u305a\u306f\u30d6\u30e9\u30a6\u30b6\u3067\u300c<strong>http:\/\/******\/clear_input<\/strong>\u300d\u3078\u30a2\u30af\u30bb\u30b9\u3057\u307e\u3059\u3002<br \/>\n\u3059\u308b\u3068\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u8868\u793a\u306b\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10993\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_2.png\" alt=\"\" width=\"426\" height=\"198\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_2.png 426w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_2-300x139.png 300w\" sizes=\"auto, (max-width: 426px) 100vw, 426px\" \/><\/p>\n<p>\u521d\u671f\u5024\u304c\u8868\u793a\u3055\u308c\u3066\u3044\u3066\u3001\u3055\u3089\u306b\u300c<strong>\u5168\u524a\u9664\u30dc\u30bf\u30f3<\/strong>\u300d\u3082\u8868\u793a\u3055\u308c\u3066\u3044\u307e\u3059\u3002<br \/>\n\u3067\u306f\u3001\u4e00\u756a\u4e0a\u306e\u5165\u529b\u30dc\u30c3\u30af\u30b9\u306b\u300c<strong>one<\/strong>\u300d\u3068\u5165\u529b\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u3069\u3046\u306a\u308b\u3067\u3057\u3087\u3046\u304b\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10994\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_3.png\" alt=\"\" width=\"442\" height=\"204\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_3.png 442w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_3-300x138.png 300w\" sizes=\"auto, (max-width: 442px) 100vw, 442px\" \/><\/p>\n<p>\u306f\u3044\u2757<br \/>\n\u6587\u5b57\u304c\u5165\u529b\u3055\u308c\u3066\u3001\u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u3002<\/p>\n<p>\u3067\u306f\u3001\u30b3\u30f3\u30bd\u30fc\u30eb\u306e\u65b9\u3082\u78ba\u8a8d\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10995\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_4.png\" alt=\"\" width=\"273\" height=\"330\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_4.png 273w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_4-248x300.png 248w\" sizes=\"auto, (max-width: 273px) 100vw, 273px\" \/><\/p>\n<p>\uff11\u6587\u5b57\u8ffd\u52a0\u3055\u308c\u308b\u3054\u3068\u306b\u5185\u5bb9\u304c\u5909\u5316\u3057\u3066\u3044\u308b\u3053\u3068\u304c\u308f\u304b\u308a\u307e\u3059\ud83d\udc4d<\/p>\n<p>\u3067\u306f\u3001\u6b21\u306b\u8868\u793a\u3055\u308c\u305f\u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u3069\u3046\u306a\u308b\u3067\u3057\u3087\u3046\u304b\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb\uff1f\uff1f<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10996\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_5.png\" alt=\"\" width=\"423\" height=\"201\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_5.png 423w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_5-300x143.png 300w\" sizes=\"auto, (max-width: 423px) 100vw, 423px\" \/><\/p>\n<p>\u306f\u3044\u2757<br \/>\n\u60f3\u5b9a\u901a\u308a\u300c<strong>one<\/strong>\u300d\u304c\u6d88\u3048\u3001\u4f55\u3082\u306a\u304f\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<p>\u6210\u529f\u3067\u3059\ud83d\ude04<\/p>\n<p>\u3067\u306f\u3001\u6700\u5f8c\u306b\uff11\u756a\u76ee\u306b\u300c<strong>one<\/strong>\u300d\uff12\u756a\u3081\u306b\u300c<strong>two<\/strong>\u300d\u3068\u5165\u529b\u3057\u3001\u300c<strong>\u521d\u671f\u5024\u3042\u308a<\/strong>\u300d\u306e\u5168\u524a\u9664\u30a2\u30a4\u30b3\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3059\u308b\u3053\u3068\u3067\u3001\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304c\u500b\u5225\u3067\u52d5\u3044\u3066\u3044\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n<p>\u3046\u307e\u304f\u3044\u304f\u3067\u3057\u3087\u3046\u304b\u2026\ud83d\ude4f<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-10997\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_6.png\" alt=\"\" width=\"434\" height=\"201\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_6.png 434w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/laravel_react_clear_input_6-300x139.png 300w\" sizes=\"auto, (max-width: 434px) 100vw, 434px\" \/><\/p>\n<p>\u306f\u3044\u2757<br \/>\n\u3044\u304f\u3064\u304b\u64cd\u4f5c\u3057\u3066\u307f\u307e\u3057\u305f\u304c\u3001\u305d\u308c\u305e\u308c\u30b9\u30bf\u30f3\u30c9\u30a2\u30ed\u30fc\u30f3\u3067\u52d5\u3044\u3066\u3044\u307e\u3059\u306d\u3002<\/p>\n<p>\u3059\u3079\u3066\u6210\u529f\u3067\u3059\u2728\ud83d\ude04\ud83d\udc4d<\/p>\n<h1>\u30c7\u30e2\u30da\u30fc\u30b8\u3092\u7528\u610f\u3057\u307e\u3057\u305f<\/h1>\n<p>\u305b\u3063\u304b\u304f\u306a\u306e\u3067\u30c7\u30e2\u30da\u30fc\u30b8\u3092\u7528\u610f\u3057\u307e\u3057\u305f\u3002<br \/>\n\u305c\u3072\u5b9f\u969b\u306b\u89e6\u3063\u3066\u307f\u3066\u304f\u3060\u3055\u3044\ud83d\udc4d<\/p>\n<p>\ud83d\udcdd <strong><a href=\"https:\/\/demo-laravel9x-vite.capilano-fw.com\/clear_input\" target=\"_blank\" rel=\"noopener\">\u30c7\u30e2\u30da\u30fc\u30b8<\/a><\/strong><\/p>\n<h1>\u4f01\u696d\u69d8\u3078\u306e\u3054\u63d0\u6848<\/h1>\n<p>\u4eca\u56de\u306e\u3088\u3046\u306b\u30a6\u30a7\u30d6\u30b7\u30b9\u30c6\u30e0\u306f\u300c\u4f7f\u3046\u4eba\u306b\u5408\u308f\u305b\u305f\u300d\u6a5f\u80fd\u3092\u958b\u767a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>IT\u30ea\u30c6\u30e9\u30b7\u30fc\u304c\u3042\u307e\u308a\u306a\u3044\u65b9\u306e\u305f\u3081\u306b\u3001\u3053\u306e\u9593\u516c\u958b\u3057\u305f\u300c\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u30ad\u30fc\u30dc\u30fc\u30c9\u300d\u3067\u306e\u5165\u529b\u3082\u53ef\u80fd\u306b\u306a\u308a\u307e\u3059\u3057\u3001\u3088\u304f\u5165\u529b\u3055\u308c\u308b\u6587\u5b57\u3092\u5165\u529b\u5019\u88dc\u306b\u3057\u3066\u9078\u629e\u3055\u305b\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u305d\u3057\u3066\u3001\u3053\u3046\u3059\u308b\u3053\u3068\u3067\u696d\u52d9\u52b9\u7387\u5316\u3092\u3059\u308b\u3053\u3068\u3067\u3001\u3088\u308a\u6ce8\u529b\u3059\u3079\u304d\u5185\u5bb9\u306b\u30a8\u30cd\u30eb\u30ae\u30fc\u3092\u4f7f\u3046\u3053\u3068\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u3082\u3057\u3053\u3046\u3044\u3063\u305f\u696d\u52d9\u6539\u5584\u3092\u3054\u5e0c\u671b\u3067\u3057\u305f\u3089\u3001\u3044\u3064\u3067\u3082\u304a\u6c17\u8efd\u306b\u3054\u9023\u7d61\u304f\u3060\u3055\u3044\u3002<br \/>\n\u304a\u5f85\u3061\u3057\u3066\u304a\u308a\u307e\u3059\u3002m(_ _)m<\/p>\n<h1>\u304a\u308f\u308a\u306b<\/h1>\n<p>\u3068\u3044\u3046\u3053\u3068\u3067\u3001\u4eca\u56de\u306f<code>Laravel + React<\/code>\u3067\u300c<strong>\u30ef\u30f3\u30af\u30ea\u30c3\u30af\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u5165\u529b\u30dc\u30c3\u30af\u30b9<\/strong>\u300d\u3092\u3064\u304f\u3063\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001\u4eca\u56de\u306f\u8a18\u4e8b\u4e2d\u3067\u3082\u66f8\u3044\u305f\u3068\u304a\u308a\u300c\u5f79\u5272\u3067\u30b0\u30eb\u30fc\u30d7\u5316\u3057\u305f\u66f8\u304d\u65b9\u300d\u3092\u3057\u307e\u3057\u305f\u304c\u3044\u304b\u304c\u3060\u3063\u305f\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n<p>\u6b63\u76f4\u306a\u3068\u3053\u308d\u3001\u300c\u30c7\u30fc\u30bf\u306f\u30c7\u30fc\u30bf\u3067\u307e\u3068\u3081\u308b\u300d\u3084\u308a\u65b9\u306e\u65b9\u304c\u5b66\u7fd2\u306b\u306f\u9069\u3057\u3066\u3044\u308b\u306e\u304b\u306a\u3068\u3044\u3046\u6c17\u306f\u3057\u3066\u3044\u308b\u306e\u3067\u3059\u304c\u3001\u30ea\u30a2\u30eb\u306e\u958b\u767a\u3067\u306f\u4eca\u56de\u306e\u3088\u3046\u306a\u66f8\u304d\u65b9\u306e\u65b9\u304c\u591a\u3044\u3088\u3046\u306a\u6c17\u3082\u3057\u307e\u3059\u3057\u3001\u8a18\u4e8b\u3092\u66f8\u304f\u5074\u3068\u3057\u3066\u306f\u60a9\u307e\u3057\u304b\u3063\u305f\u308a\u3057\u307e\u3059\uff08\u7b11\uff09<\/p>\n<p>\u305c\u3072\u7686\u3055\u3093\u3082\u3044\u308d\u3044\u308d\u3068\u8a66\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u306d\u3002<\/p>\n<p>\u3067\u306f\u3067\u306f\u301c\u2757<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-11002\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/no_10.png\" alt=\"\" width=\"370\" height=\"290\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/no_10.png 370w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2022\/09\/no_10-300x235.png 300w\" sizes=\"auto, (max-width: 370px) 100vw, 370px\" \/><br \/>\n\u300c\u9053\u3092\u8b72\u3063\u305f\u3089\u3001<br \/>\n\u6e9d\u306b\u30cf\u30de\u3063\u3066\u81ea\u8ee2\u8eca\u30d1\u30f3\u30af\u2026<br \/>\n\u3053\u3093\u306a\u30d6\u30fc\u30e1\u30e9\u30f3\u304c\u3042\u3063\u3066\u3044\u3044\u306e\u304b\u2026\u300d<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3055\u3066\u3055\u3066\u3001\u3053\u3053\u6700\u8fd1\u306fReact\u306e\u9762\u767d\u3055\u306b\u89e6\u308c\u3066\u3057\u307e\u3063\u3066\u3001\u305a\u3063\u3068React\u95a2\u9023\u306e\u8a18\u4e8b\u304c\u7d9a\u3044\u3066\u3044\u307e\u3059\u3002\uff08\u521d\u3081\u3066\u30b3\u30ed\u30b3\u30ed\u6383\u9664\u3092\u3057\u305f\u3068\u304d\u6b62\u307e\u3089\u306a\u304f\u306a\u3063\u305f\u611f\u899a\u306b\u4f3c\u3066\u307e\u3059\ud83d\udc4d &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/blog.capilano-fw.com\/?p=10981\" class=\"more-link\"><span class=\"screen-reader-text\">&#8220;Laravel + React \u3067\u30ef\u30f3\u30af\u30ea\u30c3\u30af\u3067\u30af\u30ea\u30a2\u3067\u304d\u308b\u5165\u529b\u30dc\u30c3\u30af\u30b9\u3092\u3064\u304f\u308b&#8221; \u306e<\/span>\u7d9a\u304d\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":11005,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[247,3,118,249,248],"tags":[],"class_list":["post-10981","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-inertia-js","category-laravel","category-react-js","category-tailwind-css","category-vite"],"_links":{"self":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/10981","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10981"}],"version-history":[{"count":19,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/10981\/revisions"}],"predecessor-version":[{"id":11397,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/10981\/revisions\/11397"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/media\/11005"}],"wp:attachment":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10981"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10981"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10981"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}