[{"data":1,"prerenderedAt":165},["ShallowReactive",2],{"term-f\u002Ffootgun":3,"related-f\u002Ffootgun":153},{"id":4,"title":5,"acronym":6,"body":7,"category":136,"description":137,"difficulty":138,"extension":139,"letter":140,"meta":141,"navigation":111,"path":142,"related":143,"seo":147,"sitemap":148,"stem":151,"subcategory":6,"__hash__":152},"terms\u002Fterms\u002Ff\u002Ffootgun.md","Footgun",null,{"type":8,"value":9,"toc":130},"minimark",[10,15,19,23,31,35,119,123,126],[11,12,14],"h2",{"id":13},"eli5-the-vibe-check","ELI5 — The Vibe Check",[16,17,18],"p",{},"A feature or tool that makes it really easy to shoot yourself in the foot — meaning it's easy to make a mistake that hurts you. Like a function that deletes everything if you forget one argument. Languages and APIs can be full of footguns.",[11,20,22],{"id":21},"real-talk","Real Talk",[16,24,25,26,30],{},"A footgun is a programming feature, API, or tool that is prone to misuse, leading to bugs or unintended consequences. JavaScript's ",[27,28,29],"code",{},"=="," (loose equality) and PHP's type juggling are classic examples of language footguns.",[11,32,34],{"id":33},"show-me-the-code","Show Me The Code",[36,37,42],"pre",{"className":38,"code":39,"language":40,"meta":41,"style":41},"language-javascript shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u002F\u002F JavaScript footgun:\n0 == ''    \u002F\u002F true 🤯\n0 == '0'   \u002F\u002F true 🤯\n'' == '0'  \u002F\u002F false 🤯\n\n\u002F\u002F Use === instead!\n","javascript","",[27,43,44,53,70,89,106,113],{"__ignoreMap":41},[45,46,49],"span",{"class":47,"line":48},"line",1,[45,50,52],{"class":51},"sHwdD","\u002F\u002F JavaScript footgun:\n",[45,54,56,60,64,67],{"class":47,"line":55},2,[45,57,59],{"class":58},"sbssI","0",[45,61,63],{"class":62},"sMK4o"," ==",[45,65,66],{"class":62}," ''",[45,68,69],{"class":51},"    \u002F\u002F true 🤯\n",[45,71,73,75,77,80,83,86],{"class":47,"line":72},3,[45,74,59],{"class":58},[45,76,63],{"class":62},[45,78,79],{"class":62}," '",[45,81,59],{"class":82},"sfazB",[45,84,85],{"class":62},"'",[45,87,88],{"class":51},"   \u002F\u002F true 🤯\n",[45,90,92,95,97,99,101,103],{"class":47,"line":91},4,[45,93,94],{"class":62},"''",[45,96,63],{"class":62},[45,98,79],{"class":62},[45,100,59],{"class":82},[45,102,85],{"class":62},[45,104,105],{"class":51},"  \u002F\u002F false 🤯\n",[45,107,109],{"class":47,"line":108},5,[45,110,112],{"emptyLinePlaceholder":111},true,"\n",[45,114,116],{"class":47,"line":115},6,[45,117,118],{"class":51},"\u002F\u002F Use === instead!\n",[11,120,122],{"id":121},"when-youll-hear-this","When You'll Hear This",[16,124,125],{},"\"That API is a total footgun — one wrong parameter and it wipes the database.\"",[127,128,129],"style",{},"html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":41,"searchDepth":55,"depth":55,"links":131},[132,133,134,135],{"id":13,"depth":55,"text":14},{"id":21,"depth":55,"text":22},{"id":33,"depth":55,"text":34},{"id":121,"depth":55,"text":122},"general","A feature or tool that makes it really easy to shoot yourself in the foot — meaning it's easy to make a mistake that hurts you.","beginner","md","f",{},"\u002Fterms\u002Ff\u002Ffootgun",[144,145,146],"Bug","Anti-Pattern","Error Handling",{"title":5,"description":137},{"changefreq":149,"priority":150},"weekly",0.7,"terms\u002Ff\u002Ffootgun","lTkuaT3BvGBSkhwxzp6IkcDN-VHyY0UqNEWA9FtIm3o",[154,158,161],{"title":145,"path":155,"acronym":6,"category":156,"difficulty":138,"description":157},"\u002Fterms\u002Fa\u002Fanti-pattern","architecture","Anti-Pattern is the opposite of a design pattern — it's a commonly used approach that looks like it solves a problem but actually makes things worse.",{"title":144,"path":159,"acronym":6,"category":136,"difficulty":138,"description":160},"\u002Fterms\u002Fb\u002Fbug","A bug is anything in your code that makes it behave wrong.",{"title":146,"path":162,"acronym":6,"category":136,"difficulty":163,"description":164},"\u002Fterms\u002Fe\u002Ferror-handling","intermediate","Error handling is the art of planning for things to go wrong and dealing with them gracefully instead of letting everything catch fire.",1776518281410]