Software Design by Example
Home > Computing and Information Technology > Computer programming / software engineering > Software Engineering > Software Design by Example: A Tool-Based Introduction with JavaScript
Software Design by Example: A Tool-Based Introduction with JavaScript

Software Design by Example: A Tool-Based Introduction with JavaScript

|
     0     
5
4
3
2
1




International Edition


About the Book

The best way to learn design in any field is to study examples, and some of the best examples of software design come from the tools programmers use in their own work. Software Design by Example: A Tool-Based Introduction with JavaScript therefore builds small versions of the things programmers use in order to demystify them and give some insights into how experienced programmers think. From a file backup system and a testing framework to a regular expression matcher, a browser layout engine, and a very small compiler, we explore common design patterns, show how making code easier to test also makes it easier to reuse, and help readers understand how debuggers, profilers, package managers, and version control systems work so that they can use them more effectively. This material can be used for self-paced study, in an undergraduate course on software design, or as the core of an intensive weeklong workshop for working programmers. Each chapter has a set of exercises ranging in size and difficulty from half a dozen lines to a full day’s work. Readers should be familiar with the basics of modern JavaScript, but the more advanced features of the language are explained and illustrated as they are introduced. All the written material in this project can be freely reused under the terms of the Creative Commons - Attribution license, while all of the software is made available under the terms of the Hippocratic License. All proceeds from sale of this book will go to support the Red Door Family Shelter in Toronto. Features • Teaches software design by showing programmers how to build the tools they use every day • Each chapter includes exercises to help readers check and deepen their understanding • All the example code can be downloaded, re-used, and modified under an open license

Table of Contents:
1. Introduction. 1.1. Who is our audience? 1.2. What tools and ideas do we cover? 1.3. How are these lessons laid out? 1.4. How did we get here? 1.5. How can people use and contribute to this material? 1.6. Who helped us? 2. Systems Programming. 2.1. How can we list a directory? 2.2. What is a callback function? 2.3. What are anonymous functions? 2.4. How can we select a set of files? 2.5. How can we copy a set of files? 2.6. Exercises. 3. Asynchronous Programming. 3.1. How can we manage asynchronous execution? 3.2. How do promises work? 3.3. How can we chain operations together? 3.4. How are real promises different? 3.5. How can we build tools with promises? 3.6. How can we make this more readable? 3.7. How can we handle errors with asynchronous code? 3.8. Exercises. 4. Unit Testing. 4.1. How should we structure unit testing? 4.2. How can we separate registration, execution, and reporting? 4.3. How should we structure test registration? 4.4. How can we build a command-line interface for testing? 4.5. Exercises. 5. File Backup. 5.1. How can we uniquely identify files? 5.2. How can we back up files? 5.3. How can we track which files have already been backed up? 5.4. How can we test code that modifies files? 5.5. Exercises. 6. Data Tables. 6.1. How can we implement data tables? 6.2. How can we test the performance of our implementations? 6.3. What is the most efficient way to save a table? 6.4. Does binary storage improve performance? 6.5. Exercises. 7. Pattern Matching. 7.1. How can we match query selectors? 7.2. How can we implement a simple regular expression matcher? 7.3. How can we implement an extensible matcher? 7.4. Exercises. 8. Parsing Expressions. 8.1. How can we break text into tokens? 8.2. How can we turn a list of tokens into a tree? 8.3. Exercises. 9. Page Templates. 9.1. What will our system look like? 9.2. How can we keep track of values? 9.3. How do we handle nodes? 9.4. How do we implement node handlers? 9.5. How can we implement control flow? 9.6. How did we know how to do all of this? 9.7. Exercises. 10. Build Manager. 10.1. What’s in a build manager? 10.2. Where should we start? 10.3. How can we specify that a file is out of date? 10.4. How can we update out-of-date files? 10.5. How can we add generic build rules? 10.6. What should we do next? 10.7. Exercises. 11. Layout Engine. 11.1. How can we size rows and columns? 11.2. How can we position rows and columns? 11.3. How can we render elements? 11.4. How can we wrap elements to fit? 11.5. What subset of CSS will we support? 11.6. Exercises. 12. File Interpolator. 12.1. How can we evaluate JavaScript dynamically? 12.2. How can we manage files? 12.3. How can we find files? 12.4. How can we interpolate pieces of code? 12.5. What did we do instead? 12.6. Exercises. 13. Module Loader. 13.1. How can we implement namespaces? 13.2. How can we load a module? 13.3. Do we need to handle circular dependencies? 13.4. How can a module load another module? 13.5. Exercises. 14. Style Checker. 14.1. How can we parse JavaScript to create an AST? 14.2. How can we find things in an AST? 14.3. How can we apply checks? 14.4. How does the AST walker work? 14.5. How else could the AST walker work? 14.6. What other kinds of analysis can we do? 14.7. Exercises. 15. Code Generator. 15.1. How can we replace a function with another function? 15.2. How can we generate JavaScript? 15.3. How can we count how often functions are executed? 15.4. How can we time function execution? 15.5. Exercises. 16. Documentation Generator. 16.1. How can we extract documentation comments? 16.2. What input will we try to handle? 16.3. How can we avoid duplicating names? 16.4. Exercises. 17. Module Bundler. 17.1. What will we use as test cases? 17.2. How can we find dependencies? 17.3. How can we safely combine several files into one? 17.4. How can files access each other? 17.5. Exercises. 18. Package Manager. 18.1. What is semantic versioning? 18.2. How can we find a consistent set of packages? 18.3. How can we satisfy constraints? 18.4. How can we do less work? 18.5. Exercises. 19. Virtual Machine. 19.1. What is the architecture of our virtual machine? 19.2. How can we execute these instructions? 19.3. What do assembly programs look like? 19.4. How can we store data? 19.5. Exercises. 20. Debugger. 20.1. What is our starting point? 20.2. How can we make a tracing debugger? 20.3. How can we make the debugger interactive? 20.4. How can we test an interactive application? 20.5. Exercises. 21. Conclusion.


Best Sellers


Product Details
  • ISBN-13: 9781032330235
  • Publisher: Taylor & Francis Ltd
  • Publisher Imprint: Chapman & Hall/CRC
  • Height: 254 mm
  • No of Pages: 329
  • Weight: 660 gr
  • ISBN-10: 1032330236
  • Publisher Date: 29 Dec 2022
  • Binding: Paperback
  • Language: English
  • Sub Title: A Tool-Based Introduction with JavaScript
  • Width: 178 mm


Similar Products

Add Photo
Add Photo

Customer Reviews

REVIEWS      0     
Click Here To Be The First to Review this Product
Software Design by Example: A Tool-Based Introduction with JavaScript
Taylor & Francis Ltd -
Software Design by Example: A Tool-Based Introduction with JavaScript
Writing guidlines
We want to publish your review, so please:
  • keep your review on the product. Review's that defame author's character will be rejected.
  • Keep your review focused on the product.
  • Avoid writing about customer service. contact us instead if you have issue requiring immediate attention.
  • Refrain from mentioning competitors or the specific price you paid for the product.
  • Do not include any personally identifiable information, such as full names.

Software Design by Example: A Tool-Based Introduction with JavaScript

Required fields are marked with *

Review Title*
Review
    Add Photo Add up to 6 photos
    Would you recommend this product to a friend?
    Tag this Book Read more
    Does your review contain spoilers?
    What type of reader best describes you?
    I agree to the terms & conditions
    You may receive emails regarding this submission. Any emails will include the ability to opt-out of future communications.

    CUSTOMER RATINGS AND REVIEWS AND QUESTIONS AND ANSWERS TERMS OF USE

    These Terms of Use govern your conduct associated with the Customer Ratings and Reviews and/or Questions and Answers service offered by Bookswagon (the "CRR Service").


    By submitting any content to Bookswagon, you guarantee that:
    • You are the sole author and owner of the intellectual property rights in the content;
    • All "moral rights" that you may have in such content have been voluntarily waived by you;
    • All content that you post is accurate;
    • You are at least 13 years old;
    • Use of the content you supply does not violate these Terms of Use and will not cause injury to any person or entity.
    You further agree that you may not submit any content:
    • That is known by you to be false, inaccurate or misleading;
    • That infringes any third party's copyright, patent, trademark, trade secret or other proprietary rights or rights of publicity or privacy;
    • That violates any law, statute, ordinance or regulation (including, but not limited to, those governing, consumer protection, unfair competition, anti-discrimination or false advertising);
    • That is, or may reasonably be considered to be, defamatory, libelous, hateful, racially or religiously biased or offensive, unlawfully threatening or unlawfully harassing to any individual, partnership or corporation;
    • For which you were compensated or granted any consideration by any unapproved third party;
    • That includes any information that references other websites, addresses, email addresses, contact information or phone numbers;
    • That contains any computer viruses, worms or other potentially damaging computer programs or files.
    You agree to indemnify and hold Bookswagon (and its officers, directors, agents, subsidiaries, joint ventures, employees and third-party service providers, including but not limited to Bazaarvoice, Inc.), harmless from all claims, demands, and damages (actual and consequential) of every kind and nature, known and unknown including reasonable attorneys' fees, arising out of a breach of your representations and warranties set forth above, or your violation of any law or the rights of a third party.


    For any content that you submit, you grant Bookswagon a perpetual, irrevocable, royalty-free, transferable right and license to use, copy, modify, delete in its entirety, adapt, publish, translate, create derivative works from and/or sell, transfer, and/or distribute such content and/or incorporate such content into any form, medium or technology throughout the world without compensation to you. Additionally,  Bookswagon may transfer or share any personal information that you submit with its third-party service providers, including but not limited to Bazaarvoice, Inc. in accordance with  Privacy Policy


    All content that you submit may be used at Bookswagon's sole discretion. Bookswagon reserves the right to change, condense, withhold publication, remove or delete any content on Bookswagon's website that Bookswagon deems, in its sole discretion, to violate the content guidelines or any other provision of these Terms of Use.  Bookswagon does not guarantee that you will have any recourse through Bookswagon to edit or delete any content you have submitted. Ratings and written comments are generally posted within two to four business days. However, Bookswagon reserves the right to remove or to refuse to post any submission to the extent authorized by law. You acknowledge that you, not Bookswagon, are responsible for the contents of your submission. None of the content that you submit shall be subject to any obligation of confidence on the part of Bookswagon, its agents, subsidiaries, affiliates, partners or third party service providers (including but not limited to Bazaarvoice, Inc.)and their respective directors, officers and employees.

    Accept

    New Arrivals

    Inspired by your browsing history


    Your review has been submitted!

    You've already reviewed this product!