Tag: jamstack

How To Build Vue Wordpress Rest API Websites

wpgridsome

Want to build a Vue JS/Wordpress Rest API backend hybrid, with superfast loading times? Here we take a look at Gridsome static site generator for Vue JS, which is a similar tool to React’s Gatsby generator, and build a site using the Vue Wordpress Rest API.

The use of Jamstack (Javascript, API’s and Markup) technologies is on the rise nowadays, as they provide a simpler developer experience, better performance and greater scaleability. Most React developers are familiar with the Gatsby site generator, however with Vue JS there are a number of different options. Here we take a look at the Gridsome cli for Vue JS, which has some cool features out of the box, and a lot more that can be added with the use of plugins.

Screenshot

Gridsome for Vue Wordpress

With Gridsome, you get the following out of the box, in a quick two minute install.

Local development with hot-reloading – See code changes in real-time.

Data source plugins – Connect to any popular Headless CMSs, APIs or Markdown-files.

File-based page routing – Quickly create and manage routes with files.

Centralized data management – Pull data into a local, unified GraphQL data layer.

Vue.js for frontend – A lightweight and approachable front-end framework.

Auto-optimized code – Get code-splitting and asset optimization out-of-the-box.

Static files generation – Deploy securely to any CDN or static web host.

Built-in component that outputs an optimized progressive image – resizes and crops in real-time when developing.

Everything Lives in Github

With a JAMstack project, anyone should be able to do a git clone, install any needed dependencies with a standard procedure (like npm install), and be ready to run the full project locally. No databases to clone, no complex installs. This reduces contributor friction, and also simplifies staging and testing workflows.

Modern Build Tools

Take advantage of the world of modern build tools. It can be a jungle to get oriented in and it’s a fast-moving space, but you’ll want to be able to use tomorrow’s web standards today without waiting for tomorrow’s browsers. And that currently means Babel, PostCSS, Webpack, and friends.

Automated Builds

Because JAMstack markup is prebuilt, content changes won’t go live until you run another build. Automating this process will save you lots of frustration. You can do this yourself with webhooks, or use a publishing platform that includes the service automatically.

Wordpress Rest API

Since the introduction of the Wordpress Rest API , it has opened up a whole new world of possibilities for Viue JS/Wordpress hybrids, utilizing the features above and combining them with the vast infrastructure and support available with Wordpress. Whilst this may not be suitable for many requirements, there are certainly some which will benefit from this approach.

Wordpress Vue Starter Templates

The Gridsome Wordpress setup (there are others) has the features you need to connect to a Wordpress back end to pull in data to display at the Vue front end, typically loading faster than normal and with a lot of other benefits.

For anyone interested in building a Vue JS front end and using the Wordpess Rest API Ive created some starter templates using Gridsome which have been enhanced from the standard Gridsome Wordpress starter with some extra bits, to get you up and running fast. Please note I haven’t used the g-image here, so remember to change those when inserting your own images.

The Wordpress API is https://vuewp.xhostcom.com/ and we use the endpoints from that to test some data. These are already in the config files, but if you have your own Wordpress setup you can obviously use that, just change the url in gridsome.config.js and netlify.toml

You will first need NodeJS and NPM installed, and Gridsome using the command

npm install –global @gridsome/cli

And then clone from Github any of the following starters, which will get you up and running quickly.

bulma1

Example

Code (Bulma CSS)

bulma2

Example

Code (Bulma CSS)

milli1

Example

Code (Milligram CSS)

Here’s a blank one with just a nav bar and no CSS or JS

Example

Code (No CSS)

And also my Avivo Bootstrap Vue Wordpress theme using Bootstrap & SASS/SCSS

screenshot1

Example

Code (Bootstrap 4)

Once cloned, just run Yarn to grab the dependencies, and gridsome develop command to run the test server. You can of course change the CSS and add your own Javascript as required, but these get you up and running ready to go with the Wordpress Rest API data as is.

You can just clear the markup in all the page templates back to the <Layout> tags and put in your own markup. Creation of extra pages, once added to the menu in /components/header.vue will be routed accordingly with the superfast router, one of the best features I’ve found, and a breeze compared to others such as Nuxt.

So these are just basic starter templates, there’s a lot more that can be done using the GraphQL data bindings and other functionality in Gridsome and Wordpress to create your site.

Feel free to contribute on Github.

Vue CLI 3 & UIKit

Finally, for those who prefer the official Vue JS CLI, here’s one using that, and UIKit CSS/JS Framework, with an awesome mobile nav bar! Its NOT configured for the Wordpress Rest API but can be with a little application, or you may want to port the styles using the Gridsome starter above.

Uikit

Uikit

Uikit

Example

Code (Vue CLI – UIKit)

So, there we have a few Gridsome Vue Wordpess Starters to have a look at, and also a Vue CLI with UIKit starter to play around with and get a feel for the Vue JS Wordpress API setup, although it can get a lot more interesting if we delve deeper in to Gridsomes GraphQL, extra functions and post template features.

Feel free to check them all out on Github at Xhostcomweb. If you enjoyed this post, why not check out this article on Wordpress Dynamic Content!

Post by Xhostcom Wordpress & Digital Services, subscribe to newsletter for more

Filed under: Vue JS, WordpressTagged with: , , , , , , ,

How to Start a Web Design Business

15-Best-Small-Business-Website-Examples

Many researchers predict the number of web design businesses in the United States will reach 75,531 this year, with an annual growth rate of 6.6%. As a web developer, you’re competing against big agencies as well as freelancers. Although the growth of web development businesses in the U.S. is on an upward trajectory, there is also competition from around the world. If you want to compete against all the other options available, you must consider some factors that help web design businesses stand out from the crowd and gather a loyal group of clients.

Learn Your Craft

Lemonade

The most successful web designers specialize in one or two areas. While they might know how to create parallax scrolling and can deliver that if a customer wants it, their specialty might be in mobile design. It’s essential to not only understand the basic concepts of design, but also to know coding, such as HTML, SQL and PHP. You don’t need a formal education to become a web developer, but you do need knowledge. You can gain know-how from college courses, online courses, self-guided study or hands-on learning where you intern under a more experienced designer.

Wordpress or Jamstack?

Vorteasy

The most commonly used CMS, Wordpress, powers around 30% of all websites online, and is the go to CMS for many web design agencies. Its probably the best option for most business and personal sites due to its extensive customization and 3rd party integrations, and the Woocommerce eCommerce option. However, there are newer stacks which can be useful for smaller of different kinds of site, Jamstack is one of them. Jamstack is an amalgamation of Javascript client side libraries & APIs in an agile streamlined environment and is becoming popular among many developers to produce fast functional websites.

Find Clients

Ebuilder

One of your first steps as a web design business is finding clients. Without clients, you won’t have any income, and your business will flounder. At first, your clients may be small local business owners you know personally and gigs through sites such as Fiverr and Upwork. With time, you’ll develop contacts and receive referrals from happy clients. Ideally, your client base will consist of a couple of big accounts and many smaller accounts. The larger accounts bring in plenty of cash, while the smaller ones keep the lights on and help you if you lose a big client unexpectedly. Tell everyone you know about your new business, pass out cards and network with business owners in your area.

Track Value

medchain

Understand the key performance indicators for your business and ask your teams to work with accounting to track how much time you’re spending on each client versus the money that client brings into your agency. Analyze the cost for each invoice you send to that client. For example, one client might love every design you create and sign off on the changes with only a minor tweak. Another client might hate every design you send their way and ask for revision after revision. The value of the client who rarely asks for changes is higher because they take up less of your time for the same amount of money.

Even though it’s difficult to let those first clients go as your company grows, if you want a profitable business, you must release the smaller clients who are eating up all your time. Each year, take a look at your bottom 20% in key performance indicators. Consider if the client brings in additional people through referrals and the actual cost of doing business with the people in that bottom 20%. Release the ones who are not benefiting your business so you can make room for other, better-paying clients.

Fix Problems

taylorpearson

As your business grows, you’ll run into a variety of growing pains. Every three to six months, look at the efficiency of your operations. Are customers complaining about wait times? You may need to hire another designer to keep up with demand. Are people failing to pay invoices? You may need to go to a model where clients pay 25% up front and then in increments throughout the design process.

Only about half of business startups make it past their fifth year. The most common cause of failure is due to cash flow problems. Pay close attention to money going out and money coming in, and ensure there is a balance between the two. If your employee costs are higher than your income, you’ll run out of money fast. If you’re not quite ready to hire a full-time employee, but you have more work than you can handle, hire freelancers or temporary workers to get you through the growth phase until you can afford to bring someone new into the company.

Develop a Great Team

denzilla

When you are ready to hire people to help you run your business, find the absolute best team possible. While you might not be able to pay workers the same as a large corporation, you can offer other perks a big company might not, such as bringing pets to work or offering extra days off. Create a strong company culture that feels more like a family than work, and you’re more likely to attract and keep top talent.

Improve Your CX

fps

Customer experience, or CX, is one of the most vital elements in attracting and keeping new customers. Around 67% of consumers say they expect a good experience more today than ever before. Not only should your company’s website draw in the user and keep their attention, but the CX carries on to the customer service you offer once the buyer makes a purchase and how easy it is to work with you. Excellent CX requires attention to detail and ongoing training for your employees.

Grow Your Business

Ayaygood

When you’re ready, growing your business is often as easy as asking your current customers for referrals. Word-of-mouth advertising is one of the most effective ways to reach new clients. If you’ve developed a speciality area, use social media and advertise to that market segment. Keep a close eye on your growth, with the understanding that growth is often a tipping point in cash flow issues, and you should be able to steadily grow your business year after year, making it profitable and secure. If you enjoyed this post, why not check out this article on Building Vue Wordpress Rest API websites!

Post by Xhostcom Wordpress & Digital Services, subscribe to newsletter for more!

Filed under: eCommerce, Trends, WordpressTagged with: ,