Sponsor webpack and get apparel from the official shop! All proceeds go to our open collective!

bundle your
assets scripts

STATIC ASSETS .png .css .jpg .js MODULES WITH DEPENDENCIES .jpg .png .sass .sass .js .sass .cjs .hbs .js

Write your code


import bar from './bar';



export default function bar() {

Bundle with webpack

Without config or provide custom webpack.config.js

const path = require('path');

module.exports = {
  entry: './src/index.js',
  output: {
    path: path.resolve(__dirname, 'dist'),
    filename: 'bundle.js'


<!doctype html>
    <script src="dist/bundle.js"></script>

Then run webpack on the command-line to create bundle.js.

It's that simple

Get Started quickly in our Guides section, or dig into the Concepts section for more high-level information on the core notions behind webpack.

Support the Team

Through contributions, donations, and sponsorship, you allow webpack to thrive. Your donations directly support office hours, continued enhancements, and most importantly, great documentation and learning material!

Latest Sponsors

The following persons/organizations made their first donation in the last 14 days.

Mölkky World's avatarAndrea Unger's avatarJulian Kani's avatarAdam Zhu's avatarDavid James's avatarOlivier Mourlevat's avatarBonus Koodit's avatarLotto tulokset's avatarWasserhelden.Net's avatarShunfan Du's avatar

Platinum Sponsors

platinum sponsorsare those who have pledged $50,000 or more to webpack.

trivago's avatar

Gold Sponsors

gold sponsorsare those who have pledged $10,000 to $50,000 to webpack.

ag-Grid's avatarSegment's avatarAirbnb's avatarFacebook Open Source's avatarAdobe's avatarCapital One's avatarFrontend Masters's avatarIndeed's avatar

Silver Sponsors

silver sponsorsare those who have pledged $2,000 to $10,000 to webpack.

Coinbase's avatarSlack's avatarWebflow's avataregghead.io's avatarAMP Project's avatarTipe's avatarThreadless Shop's avatarPeerigon's avatarN26's avatarRollbar's avatar上线了's avatarKeyCDN's avatarSentry.io's avatarGoogle Angular's avatarPhotoEditorSDK's avatarWaffle.io's avatarAlligator.io's avatarJared Palmer's avatarSticker Mule's avatar5 minutes of React podcast's avatarAccelebrate's avatarHubSpot's avatar

Bronze Sponsors

bronze sponsorsare those who have pledged $200 to $2,000 to webpack.

Free Icons by Icons8's avatarKent C. Dodds's avatarAppfolio's avatarAddy Osmani's avatarBlockchain Training Alliance 's avatarclay's avatarTeam Extension's avatarVTEX's avatarX-Team's avatarSebastian Software GmbH's avatarAlgolia's avatarProductReview.com.au's avatarBCG Digital Ventures's avatarFire Stick Tricks's avatarEsben Petersen's avatarZEIT's avatarSarah Drasner's avatarsynedra IT GmbH's avatarYvo Schaap's avatarJoshua Wiens's avatarAndrew Lunny's avatarSoftwarePlant's avatarModus Create's avatarClevertech's avatarJetRuby Agency's avatarOmega Media's avatarVolare Systems's avatarThe Training Advisors's avatarStatus Hero's avatarIrvin Waldman's avatarDan Abramov's avatarCerner Engineering 's avatarreBuy's avatarAviture Inc.'s avatarChristian Alfoni's avatarDontPayFull's avatarReact Native Training's avatarArchitects.io's avatarWork & Co's avatarClaudio Rodriguez's avatarBen Vinegar's avatarFred Carlsen's avatarWonmin's avatarDarko Kukovec's avatarCory House's avatarJonathan Soifer's avatarJonathon Landon's avatarCodePilot.ai's avatarAlex Liang's avatarRagunath Ramaswamy's avatarMixmax's avatarDerk-Jan Karrenbeld @SleeplessByte's avatarRob Kielty's avatarJayshri Sing's avatarI Done This's avatarEvgeny Rodionov's avatarByteScout's avatar


The following Backers are individuals who have contributed various amounts of money in order to help support webpack. Every little bit helps, and we appreciate even the smallest contributions.

Adam's avatar
Kevin James's avatar
Karolis Astrauka's avatar
Mike Murry's avatar
Eliseu Monar dos Santos's avatar
Sasha Koss's avatar
TaopaiC Tao's avatar
Shiva Nandan's avatar
Chris Freeman's avatar
ngAtl Conf's avatar
Emilio Martinez-Cordero's avatar
Lochlan Bunn's avatar
Evan Jacobs's avatar
Suman Bharadwaj's avatar
Matteo's avatar
谢彪's avatar
Chris Lloyd's avatar
Eric Clemmons's avatar
Nicolas Roos's avatar
Johannes Weber's avatar
Davin Hills's avatar
Knovour Zheng's avatar
Simon Kjellberg's avatar
kuma's avatar
Uptrend Technology, Inc.'s avatar
Lagged's avatar
david8's avatar
Botika's avatar
Steve Ricciardelli's avatar
Vladimir Starkov's avatar
Parker Bond's avatar
Conor Hastings's avatar
Shane Eckel's avatar
Jeremy Schlatter's avatar
dev_to's avatar
Matt lewis's avatar
Umut Sirin's avatar
Jonathan Kim's avatar
Joel Chen's avatar
Adam Recvlohe's avatar
Travis Arnold's avatar
Gil Barbara's avatar
Rafał Filipek's avatar
Mark van den Brink's avatar
Indexed's avatar
MoonMail's avatar
Ben Cao's avatar
Neven Rodić's avatar
drdla's avatar
Say Yup's avatar
Leonard Souza's avatar
Tirell's avatar
Thorsten Lünborg's avatar
Eric Lanehart's avatar
Adam Egesa's avatar
Robert Fruchtman's avatar
Aaron Trostle's avatar
Simen Brekken's avatar
Dzianis Sheka 's avatar
александр староверов's avatar
Open Listings's avatar
MicroPyramid's avatar
Oliver Zeigermann's avatar
Valentin Semirulnik's avatar
Yong Su's avatar
Sidnet's avatar
PerfPerfPerf's avatar
Jorge Antunes's avatar
Michael Van Diest's avatar
Sean Clayton's avatar
AB's avatar
Albert Chang's avatar
Jon Seidel's avatar
Jonas Strømsodd's avatar
Suhas Deshpande's avatar
mqklin's avatar
Matters's avatar
Say Yup's avatar
Ajit Singh's avatar
spalger's avatar
Alex Leung's avatar
Eugene Baranov's avatar
Zachary Origitano's avatar
jules's avatar
Kevin Ball's avatar
Vladimir Z's avatar
Martin Fischer's avatar
Sean Larkin's avatar
Oliver's avatar
Ross Kaffenberger's avatar
Alexander Shakun's avatar
Jacob Peddicord's avatar
Arjun Sarode's avatar
Reinier Kaper's avatar
Tyler McGinnis's avatar
jdinhify's avatar
Rey Bango's avatar
Yevgen Safronov's avatar
Carlos Guimaraes's avatar
Francisco Olmedo's avatar
Stephen R's avatar
GiveMeDeals's avatar
Paul Kotets's avatar
Dylan Kirkby's avatar
Knoji's avatar
bmqb's avatar
Nicolai Pascal Großer's avatar
Chris Villanueva's avatar
Michael Loughry's avatar
Dealfy.co.uk's avatar
DomaiNesia's avatar
Michiel Westerbeek's avatar
Brandon Pierce's avatar
Jeremy Morrell's avatar
Sijie Tian's avatar
Mitchell Gates's avatar
CarHP's avatar
Mark Drake's avatar
Dan Grebb's avatar
Richard's avatar
Kevin Clement's avatar
Jarrod Davis's avatar
Waiterio's avatar
Alexander Wunschik's avatar
Eduard Kyvenko's avatar
Anatoliy Yastreb's avatar
Mark Thomas's avatar
Denny Schuldt's avatar
Felipe Amorim's avatar
José Diaz Seng's avatar
Ching-Ting Wu's avatar
Jacob Mischka's avatar
Gregory Nowakowski's avatar
Blake Cerecero's avatar
Wellington Soares's avatar
Samir Damle's avatar
manuelbieh's avatar
Alexander Mostovenko's avatar
Benjamin Geese's avatar
Guillermo Sanchez's avatar
Sunil Pai's avatar
James Cham's avatar
Freegames66.com's avatar
Ricky de Laveaga's avatar
Carey Hinoki's avatar
Adam Eury's avatar
Ron McCranie's avatar
Charlie Wettlaufer's avatar
Ryan Helmoski's avatar
anonymous's avatar
Rob Mellett's avatar
Andrew Vieyra's avatar
Kelly Burke's avatar
Jason Laster's avatar
Kiyohito Kuwahara's avatar
InstaCasino's avatar
Norges Casino's avatar
Maximiliano Castro's avatar
Miguel González López's avatar
SpillOdds's avatar
Grgur Grisogono's avatar
Josh Dzielak's avatar
Jurica Železnjak's avatar
Alejandro Brozzo's avatar
Corjen's avatar
Asgard OU's avatar
Selçuk Kiraz's avatar
Jean-Luc Geering's avatar
Aaron Godin's avatar
Giovanni Orlando's avatar
Mark Lozano's avatar
Rude Ayelo's avatar
Espen Hovlandsdal's avatar
Greg Venech's avatar
Guilherme Rodrigues's avatar
David Jungst's avatar
Matt Palmer's avatar
Phil-lgr's avatar
Hozefa Jodiawalla's avatar
Craig Doremus's avatar
Kevin Pruett's avatar
Jonathan Reem's avatar
paulhiers's avatar
David Ang's avatar
Sambla OY's avatar
Rohit Kumar's avatar
Eugene Molokov's avatar
French Toasters LLC's avatar
Oliver's avatar
Matt Hargett's avatar
Bruno Mota's avatar
Mike Joyce's avatar
Tim Griesser's avatar
Darren Scerri's avatar
Harun Hasdal's avatar
Artur Ptaszek's avatar
Davison Long's avatar
李勇's avatar
Alexander Wunschik's avatar
Chris Williams's avatar
Khiet Vo's avatar
Dylan Byth's avatar
Johan Wendelstam's avatar
Davidson Fellipe's avatar
Cale Newman's avatar
meyer's avatar
Mike Auclair's avatar
Peter Šulek's avatar
Jeevan Palakurty's avatar
JD's avatar
Josh Lavely's avatar
Spenser Isdahl's avatar
Yinan Fang's avatar
zhaojun's avatar
Two Bucks's avatar
Rolf Lekang's avatar
Ken Colton's avatar
PromoCodeWatch's avatar
Rich Seviora's avatar
Dealspotr's avatar
Yazan Aabed's avatar
Craig Rubino's avatar
Cody Mercer's avatar
Java Tutorial's avatar
Steve McPherson's avatar
Marcus Nielsen's avatar
Dean Pogni's avatar
Arthur Stolyar's avatar
Vu Tran's avatar
Eddy Hernandez's avatar
Matija Marohnić's avatar
Andrey Koperskiy's avatar
Gavin Mogan's avatar
Jorge Cuadra's avatar
Restuta's avatar
http://kaspertontti.fi's avatar
Daniel Jenkins's avatar
Alon David's avatar
Daniel Treasure's avatar
Instant's avatar
Gaël Marziou's avatar
webpackpro's avatar
Dan J's avatar
Phil Plückthun's avatar
Kevin Killingsworth's avatar
Viktor Hubert's avatar
Valentin Agachi's avatar
Andrew Rota's avatar
Philipp Andreychev's avatar
Bulan's avatar
Pedro Luz's avatar
Christian Kaltepoth's avatar
Matt Welke's avatar
Sara Vieira's avatar
Andrey Knupp Vital's avatar
Jiyin Yiyong's avatar
александр темный's avatar
Anton Alexandrenok's avatar
Jeremia Kimelman's avatar
Alexander Pustomelnyk's avatar
Kanitkorn Sujautra's avatar
Andy Brown's avatar
Timothy Bula's avatar
Ginhing Lee's avatar
Timber.io's avatar
Pavel Kornev's avatar
Kurtis Kemple's avatar
Maris Zemgalis's avatar
Dmitry Kabak's avatar
Jordi Teddy's avatar
Evgeny Samsonov's avatar
Gustavo Muñoz's avatar
Cucumber Limited's avatar
Daiquiri.io's avatar
Owen Buckley's avatar
Andrey Popp's avatar
Axo Finans SE's avatar
XL Helse's avatar
Sambla AB's avatar
Kyle Warren's avatar
Web Desserts's avatar
Mukesh Soni's avatar
Jamie Athanassakis's avatar
Riderman De Sousa Barbosa's avatar
Axo Finans's avatar
Ivan Lagunovsky's avatar
Alex Chen's avatar
Drathal's avatar
Cassio Cardoso's avatar
Alexey Raspopov's avatar
Endel Dreyer's avatar
Refael Dakar's avatar
Jake Day's avatar
Robert Požarickij's avatar
Adam Howard's avatar
omar mashaal's avatar
Jack Zhang's avatar
Nabarun Bhowmick's avatar
Priou's avatar
Eduardo Rabelo's avatar
Jason Baciulis's avatar
Kenneth Brubaker's avatar
Ari Palo's avatar
Keith Ito's avatar
Arti Villa's avatar
Jan-Kanty Pawelski's avatar
Ben Vinegar's avatar
Richard Worsfold's avatar
Nathan Hunzaker's avatar
modulom's avatar
Ameya Koshti's avatar
Colin Wren's avatar
Ryan Graham's avatar
scottadamsmith's avatar
Kevin Scheffelmeier's avatar
Carlos Pérezpriego's avatar
Brainly's avatar
Eirik Birkeland's avatar
Snaptortoise's avatar
Patrick Szczypinski's avatar
Sarah Alsager's avatar
Chen Pang's avatar
Joel Kemp's avatar
Andrei Zvonimir Crnković's avatar
Kevin Maes's avatar
Martin Kammersberger's avatar
Prince Bechani's avatar
Dexter Haslem's avatar
Andreas Keller's avatar
Kostas Manionis's avatar
Dan DiGangi's avatar
Matt Dionis's avatar
Moritz Mahringer's avatar
Samir Alajmovic's avatar
Karan Nijhawan's avatar
Sergey Sharov's avatar
Santeri Hiltunen's avatar
Luka Maljic's avatar
Leonidas Esteban's avatar
Tamouse Temple's avatar
Restpack's avatar
Charles Pinnix's avatar
Josema EnZo's avatar
Klemen Slavic's avatar
13web's avatar
Zack Ward's avatar
Ryan Johnson's avatar
Ben McCormick's avatar
Ready Chi's avatar
Robert Borg's avatar
Anders Hansen's avatar
Rocco Curcio's avatar
Restrry Mike's avatar
Tom Liu's avatar
Anup's avatar
Vladimir Kalinichev's avatar
Erik Fox's avatar
Sam Julien's avatar
Pedro Piñera Buendía's avatar
Giorgio Natili's avatar
Sylvain's avatar
binkpitch's avatar
Emanuele Rampichini's avatar
多会's avatar
Andi Semler's avatar
Biohackers Lab's avatar
Noah Lemen's avatar
Christopher McKnight's avatar
Cindy Haden's avatar
Michael Loughry's avatar
CasinoExpo's avatar
Lukas Mollberg's avatar
Artur Kulig's avatar
Mark Fayngersh's avatar
Viesturs Teivāns's avatar
Oliver Wehn's avatar
Bhargav Ponnapalli's avatar
Maxflow BVBA (BE 0550.758.377)'s avatar
Graham Holborn's avatar
anonymous's avatar
Connor Clark's avatar
Robert Knight's avatar
Zoutons's avatar
Daniel O'Connor's avatar
Hongmin Qiao's avatar
George Yong's avatar
Woojin Joe's avatar
G P's avatar
Ronald ChanOu's avatar
Niel de la Rouviere's avatar
kkpoon's avatar
Alex Parish's avatar
Hank Andre's avatar
Theo Salzmann's avatar
IO Space's avatar
Constructor Labs's avatar
Fravic's avatar
Paul Davis's avatar
Evgeny Timoshenko's avatar
Mustafa Rashid's avatar
alinnert's avatar
Andor Polgar's avatar
Dale Price's avatar
Hugo Freitas's avatar
Gene Chulkov's avatar
Kevin Ortman's avatar
Eric Feng's avatar
Navid Shekoufa's avatar
Mike Elsmore's avatar
Vertigo Studio SRL's avatar
Dano Alexander's avatar
Ziad Jammal's avatar
Dusan Radojevic's avatar
Spencer Hamm's avatar
Luke Bennett's avatar
WenmingTang's avatar
Mattias Johansson's avatar
Kevin Scott's avatar
Animalsluxury's avatar
Kontaktlinsen-Preisvergleich GmbH's avatar
GuruGate's avatar
HostPresto's avatar
Owen Kelly's avatar
Gustaf Brostedt's avatar
Longzheng Zhu's avatar
Aseem Sood's avatar
Daniel Arthur Gallagher's avatar
Craig Kochis's avatar
Unhype's avatar
Chris Nienhuis's avatar
Manatsawin Hanmongkolchai's avatar
Jaap Lorier's avatar
Alejandro Ortiz's avatar
Sebastian De Deyne's avatar
Dani Llops's avatar
Renato Alves's avatar
Luís Fontes's avatar
加藤賢太's avatar
Kristoffer Brabrand's avatar
Ryan Tallmadge's avatar
Freegames66's avatar
Elberth Jaimes's avatar
Led Grow Lights's avatar
Even Stensberg's avatar
Mobiparts's avatar
Sam Chen's avatar
anonymous's avatar
Ted Chirvasiu's avatar
Matter Mattress's avatar
CouponArea's avatar
CasinoTopp.net's avatar
Norske spilleautomater's avatar
FinansTopp.no's avatar
Spencer Prost's avatar
Mike Allanson's avatar
Ferdinand Salis-Samaden's avatar
Patrick Arminio's avatar
Vlad Kosinov's avatar
Sean Matheson's avatar
Alexander Kozhevin's avatar
Henry Zhu's avatar
Jian Wei Gan's avatar
Jose Quintana's avatar
Matt Clarke's avatar
Julian Modesto's avatar
Joan Llenas's avatar
Jason Kelly's avatar
Eric Stumper's avatar
Snow Liang's avatar
Michal Hantl's avatar
Pat Khunachak's avatar
Georgio Wan's avatar
Daniel Tschinder's avatar
Krzysztof Matysiak's avatar
Wen Tian Zhang's avatar
Matias Arellano's avatar
Rene Herrmann's avatar
안희종's avatar
Malek Hakim's avatar
kazz's avatar
anonymous's avatar
Petagadget's avatar
Elegant Media's avatar
Intreba's avatar
Steve's avatar
Lucas Farías's avatar
Anton Moiseev's avatar
JobNinja GmbH's avatar
Domain Promo's avatar
Jason Tokoph's avatar
Currency Converter's avatar
Digifly Marketing's avatar
Z Roofing & Waterproofing's avatar
Let's Remodel's avatar
Albany Tree & Property Service's avatar
Blue Link SEO's avatar
yashar ghaffarloo's avatar
Tom Elger's avatar
Naoki Endoh's avatar
Solderingexpert.com's avatar
Chad Williams's avatar
Achievement Games's avatar
Oliver Lassen's avatar
Sebastien K's avatar
Maarten Tibau's avatar
Kim H's avatar
Ben Halpern's avatar
Jack Moore's avatar
Infinite Loop Development Ltd's avatar
imolorhe's avatar
yoursmarthomeguide's avatar
Joshua Baker's avatar
Arvid Lundgren's avatar
anonymous's avatar
Guillaume Luccisano's avatar
Sergii Rudenko's avatar
Transmutable's avatar
Par Arvid's avatar
Karl Ingraham's avatar
Mölkky World's avatar
Andrea Unger's avatar
Julian Kani's avatar
Adam Zhu's avatar
David James's avatar
Olivier Mourlevat's avatar
lei's avatar
Mario Estrada's avatar
Perry Poon's avatar
Mobilunity's avatar
Harold Crow's avatar
Bobbink - Ferienparkspecials's avatar
Yanagi Motonari's avatar
Sergio Xalambrí's avatar
Matthew Erker's avatar
Alexander Kaiser's avatar
Patrick Collison's avatar
Ivan Zusko's avatar
henri js framework's avatar
Therefore Interactive's avatar
Drill Press Pro's avatar
Valuuttamuunnin's avatar
Valutaomvandlare's avatar
Casinokompassi's avatar
Allbestops Product Reviews's avatar
ZurrTum's avatar
Wadav's avatar
anonymous's avatar
Top Pfannen's avatar
Ryota Murakami's avatar
Ke Wang's avatar
Askfinancer's avatar
Mircea Dinoiu's avatar
Vincent Voyer's avatar
Luke Page's avatar
Emmanuel Vuigner's avatar
Joe Palladino's avatar
Tadeja Firman's avatar
Philip John Basile's avatar
Chaitanya K's avatar
Mikko's avatar
Small Business Seo's avatar
Strømtest.no's avatar
Redbox TV's avatar
Jehong Ahn's avatar
Divi Wordpress's avatar
Asgard Analytics, Inc.'s avatar
Matan Kushner's avatar
Trevor Waddell's avatar
TitanFile's avatar
JACK MA's avatar
Staffab Bergh's avatar
DadsWorksheets.com's avatar
Nickolay Marchenko's avatar
Xavier Damman's avatar
Vsevolod Okhrin's avatar
Kotisivut yritykselle's avatar
Peace Ngara's avatar
Nokey King's avatar
aga5tya's avatar
Nir Galon's avatar
Patrick Roza's avatar
Tatsuya Nakano's avatar
Christian Matsoukis's avatar
Olivier Combe's avatar
Mohammad Umair Khan's avatar
Maxim Procopenco's avatar
Dani Klein's avatar
Thomas Randolph's avatar
Dmitry Matveev's avatar
Lorenzo Sicilia's avatar
Patrick Neschkudla's avatar
admin6's avatar
Mohamad Al Asmar's avatar
Peak Digital K.K.'s avatar
Colton Colcleasure's avatar
Bharath's avatar
Dmitry Olshansky's avatar
sven alfred's avatar
Michael Lebas's avatar
Andrey Kravtsov's avatar
Dinakar Tumu's avatar
Anri Asaturov's avatar
Craig Nguyen's avatar
Marlen Gevorkyan's avatar
Zaeburn Mercer's avatar
Kotisivut yritykselle's avatar
Frederico Hoffmann's avatar
Ankur J's avatar
anonymous's avatar
Live NetTV's avatar
smartcode's avatar
Best Angle Grinder's avatar
James's avatar
VoucherCopy UK's avatar
Haarentfernung Ratgeber's avatar
Adult Work's avatar
Casinosenpai's avatar
WhatsTheHost's avatar
anonymous's avatar
Nurlan Alekberov's avatar
anonymous's avatar
anonymous's avatar
François Hodierne's avatar
Uudet nettikasinot's avatar
ilmaiskierrosta's avatar
David Johnston's avatar
anonymous's avatar
Privatlan24's avatar
Casinoupplevelse's avatar
Linnea Rogsted's avatar
esportbet4all's avatar
Freshface's avatar
imgVEHICLE's avatar
Bonuskoodit's avatar
BluePromoCode's avatar
Antonio Yee's avatar
Anas Barghoud's avatar
Suraj Poddar's avatar
anonymous's avatar
Soichiro Miki's avatar
Kirill Shevchenko's avatar
Moritz Sattler's avatar
Dana Woodman's avatar
Rachel Tublitz's avatar
Josh Manders's avatar
Viliam Elischer's avatar
Bnaya Zilberfarb's avatar
Sarah Lim's avatar
Kazuhito Higashioka's avatar
John Manoogian III's avatar
Anh Le Hoang's avatar
wusan's avatar
Brainly's avatar
Asjad Saboor's avatar
Cody Chan's avatar
Eadepardazan's avatar
Elías Rafael  Rodelo Osorio's avatar
Jaeseung Yum's avatar
Dirk Preising's avatar
oguzhan susam's avatar
Nathan Walker's avatar
anonymous's avatar
Agva Kraft's avatar
Deleted's avatar
Jacob Adler's avatar
Bonus Koodit's avatar
Lotto tulokset's avatar
Wasserhelden.Net's avatar
Shunfan Du's avatar
Kushal Pandya's avatar
Niran Babalola's avatar
Alexander Grigoriev's avatar
Rimita Green's avatar
Riyadh Al Nur's avatar
Kiem Hoang's avatar
2x3's avatar
Carlos De La Torre Fregoso's avatar
SkillFlow's avatar
Junjie Huang's avatar
Open Source Collective 501c6 (Non Profit)'s avatar
Open Source Collective org (deprecated)'s avatar
Sk's avatar
Marc Grabanski's avatar