{"id":853,"date":"2022-09-12T18:32:35","date_gmt":"2022-09-12T18:32:35","guid":{"rendered":"https:\/\/glossary.dream.press\/glossary\/%group%\/import\/"},"modified":"2025-05-07T22:10:11","modified_gmt":"2025-05-07T22:10:11","slug":"import","status":"publish","type":"glossary","link":"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/","title":{"rendered":"Import"},"content":{"rendered":"\n<p>Importing files allows developers to reuse code and keep their projects organized. There are a few different ways to import files in web development.<\/p>\n\n\n\n<p>For example, using a <em>script<\/em> tag is the most common way to import <a href=\"https:\/\/www.dreamhost.com\/glossary\/web-design\/javascript\/\">JavaScript<\/a> files into <a href=\"https:\/\/www.dreamhost.com\/glossary\/web-design\/html\/\">HTML<\/a>. You can use the <em>script<\/em> tag to include external JavaScript files and inline JavaScript code. However, to use this method, the src attribute of the <em>script<\/em> tag must be set to the <a href=\"https:\/\/www.dreamhost.com\/glossary\/domains\/url\/\">URL<\/a> of the file.<\/p>\n\n\n\n<p>Another option is to import files in JavaScript using the import keyword. You must use the import keyword at the top of the file before any code is executed. To use this method, you\u2019ll need to specify the URL of the file to be imported after the import keyword.<\/p>\n","protected":false},"featured_media":0,"parent":0,"menu_order":0,"template":"","meta":{"_acf_changed":false,"_yoast_wpseo_metadesc":"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory."},"group":[19],"class_list":["post-853","glossary","type-glossary","status-publish","hentry","group-web-design"],"acf":{"cta":"Custom Web Design","term_definition":"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory.","h2_more":"More About Importing","title_tag":"What Does Import Mean?"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>What Does Import Mean? - DreamHost Glossary<\/title>\n<meta name=\"description\" content=\"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"What Does Import Mean? - DreamHost Glossary\" \/>\n<meta property=\"og:description\" content=\"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dreamhost.com\/glossary\/web-design\/import\/\" \/>\n<meta property=\"og:site_name\" content=\"DreamHost Glossary\" \/>\n<meta property=\"article:modified_time\" content=\"2025-05-07T22:10:11+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"What Does Import Mean? - DreamHost Glossary","description":"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/","og_locale":"en_US","og_type":"article","og_title":"What Does Import Mean? - DreamHost Glossary","og_description":"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory.","og_url":"https:\/\/www.dreamhost.com\/glossary\/web-design\/import\/","og_site_name":"DreamHost Glossary","article_modified_time":"2025-05-07T22:10:11+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/","url":"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/","name":"What Does Import Mean? - DreamHost Glossary","isPartOf":{"@id":"https:\/\/glossary.dream.press\/glossary\/#website"},"datePublished":"2022-09-12T18:32:35+00:00","dateModified":"2025-05-07T22:10:11+00:00","description":"Import is a web development term that refers to moving files or libraries from one file or directory into another. For a file to be imported, it must first be exported by another file or directory.","breadcrumb":{"@id":"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/glossary.dream.press\/glossary\/web-design\/import\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/glossary.dream.press\/glossary\/web-design\/import\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.dreamhost.com\/glossary\/"},{"@type":"ListItem","position":2,"name":"Terms","item":"https:\/\/www.dreamhost.com\/glossary\/%group%\/"},{"@type":"ListItem","position":3,"name":"Import"}]},{"@type":"WebSite","@id":"https:\/\/glossary.dream.press\/glossary\/#website","url":"https:\/\/glossary.dream.press\/glossary\/","name":"DreamHost Glossary","description":"","publisher":{"@id":"https:\/\/glossary.dream.press\/glossary\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/glossary.dream.press\/glossary\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/glossary.dream.press\/glossary\/#organization","name":"DreamHost","url":"https:\/\/glossary.dream.press\/glossary\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/glossary.dream.press\/glossary\/#\/schema\/logo\/image\/","url":"https:\/\/glossary.dream.press\/glossary\/wp-content\/uploads\/2022\/10\/dreamhost-glossary-social.jpg","contentUrl":"https:\/\/glossary.dream.press\/glossary\/wp-content\/uploads\/2022\/10\/dreamhost-glossary-social.jpg","width":2400,"height":1256,"caption":"DreamHost"},"image":{"@id":"https:\/\/glossary.dream.press\/glossary\/#\/schema\/logo\/image\/"}}]}},"lang":"en","translations":{"en":853,"es":1586,"fr":7443,"nl":7464,"it":8605,"pt":9378,"pl":9409,"de":9414,"uk":9472,"ru":9494},"pll_sync_post":[],"_links":{"self":[{"href":"https:\/\/glossary.dream.press\/glossary\/wp-json\/wp\/v2\/glossary\/853","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/glossary.dream.press\/glossary\/wp-json\/wp\/v2\/glossary"}],"about":[{"href":"https:\/\/glossary.dream.press\/glossary\/wp-json\/wp\/v2\/types\/glossary"}],"wp:attachment":[{"href":"https:\/\/glossary.dream.press\/glossary\/wp-json\/wp\/v2\/media?parent=853"}],"wp:term":[{"taxonomy":"group","embeddable":true,"href":"https:\/\/glossary.dream.press\/glossary\/wp-json\/wp\/v2\/group?post=853"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}