The difficulty here is in erroneously thinking that God exists within time, and is subject to time. In reality, God exists outside of both time and space. Time is a property of the material universe. Time came into being at the point at which God created the material universe. Before Creation, there was no time.
This means that there is no such thing as God "before creation" if we think of this in temporal terms, nor is there any such thing as "from eternity" if conceived of in temporal terms. Rather, God exists in an eternity and infinity of state, in which all things of time and space are present in a single view. There was never a "time" when God did not have created beings to love.
As for love as a divine attribute, divine love is the substance and power of God, from which all of Creation flows, and by which all of Creation is kept in existence moment-to-moment. Love, in its essence, is union. In human terms, love is giving to others from ourselves, and feeling other people's joy as joy in ourselves. This is infinitely true of God's love.
Now to explain these things more fully, based on the theology of Emanuel Swedenborg (1688–1772), which rejects the Nicene Christian doctrine of the Trinity of Persons.
(Please note: Since this is not a biblical basis question, no effort will be made to provide the biblical basis for the answer given here, nor would there be space to do so properly while answering the question that was asked. Please do not complain in the comments that I haven't quoted the Bible in support of this answer! Such comments will be flagged for moderator deletion, without comment or response.)
Time and space are properties of the material universe
Before the advent of modern science, people commonly thought of time and space as a sort of gridwork in which the universe unfolds, like the x and y axes in which a graph is charted. Present-day science, however, sees time and space as properties of matter. Large masses, such as suns and galaxies, are known to bend space around them. And in present-day science, time is not measured as the fixed and unvarying ticking of a clock, in which events unfold. Rather, it is known and measured to be variable based on the relative speeds at which objects are traveling. Without this relativistic measuring of time, the rockets we send to the Moon and Mars would miss those bodies altogether, and fly off into space.
As an example of time being variable based on physical factors, if a group of people were to travel in a spacecraft at 50% of the speed of light for a year according to their onboard clocks, in a loop that returned them back to earth at the end of their journey, when they arrived back home the people on earth would have gone through a whole year plus almost eight weeks more.
In short, we now know that time is not some external gridwork in which events unfold, but is actually an intrinsic property of physical matter. The same is true of space. Outside of the physical universe, time and space have no meaning and no existence.
Time and space came into existence with the creation of the material universe
Because time and space are properties of the material universe, there is no time and space as we know it outside of the material universe.
Time began when the material universe began. From a theistic perspective, this means that time began at the moment of creation. From a scientific perspective, another way of saying this is that time began with the Big Bang.
This also means that there is no such thing as "before creation" if we think of this in terms of time. God did not exist in an eternity of time before the creation of the universe, because there was no time before the creation of the universe.
Here is how Swedenborg explains this:
Since we on earth cannot help basing our thinking on ideas that are spatial and temporal, we cannot conceive of the immensity of God before there was space or the eternity of God before there was time. In fact, if we try to conceive of them, our mind more or less loses consciousness, like a shipwrecked person who has fallen in the ocean or like someone being swallowed in an earthquake. Indeed, if we rashly persevere in that pursuit, we can easily go insane and end up denying the existence of God.
Once I myself was in a state like that. I thought and thought about what God did from eternity, what he did before the world was constructed. I wondered whether he debated the act of creation and worked out a sequence he would follow. I pondered whether mental debate was possible in a pure vacuum, and other useless questions. To prevent these considerations from driving me insane, the Lord lifted me into the atmosphere and light of inner angels. As factors related to space and time in my former thinking were somewhat removed there, I became able to understand that God's eternity is not an eternity of time. Since there was no time before the world came about, I realized that it was completely pointless to ponder such questions about God. Furthermore, since the Divine "from eternity," that is, the Divine independent of time, did not involve days, years, and centuries—they were all an instant for God—I concluded that God did not create the world in a preexisting context of time; time was first introduced by God as part of creation. (True Christianity #31:2–3, emphasis added)
It is impossible to understand the meaning of "from eternity" if we think of it in temporal terms
As suggested in the quote from True Christianity just above, attempting to think about God existing from eternity through an eternity of time before the moment of creation leads to unsound thinking and false conclusions. Swedenborg writes:
If a natural man makes up his mind to believe nothing apart from what he can apprehend he lays himself open to grossly mistaken ideas. And as it is with space and time, so it is also with many other matters. For example, a natural man inevitably falls into a nonsensical way of thinking about God when with notions involving the passage of time he contemplates what God was doing before the creation of the world, that is, what He was engaged in from eternity up to then. Nor can he be extricated from that tangled knot until notions of time and space are banished. When angels contemplate that eternity they never do so with notions of time but with ideas of state. (Arcana Coelestia #8325:2)
Man is quite incapable of possessing any idea of what is eternal except from what is temporal. And being incapable of having any idea other than this he is incapable of comprehending what "from eternity" is and so what the Divine prior to the existence of time or creation of the world is. And as long as his thinking contains any idea at all that is formed from what is temporal, he slips inevitably, if he thinks about what is eternal, into errors from which he cannot be rescued. But the angels, whose ideas are not formed from anything temporal but from timeless state, are enabled to perceive it supremely well, for to them eternity is not eternity of time but eternity of state devoid of any idea of that which is temporal. (Arcana Coelestia #3404:2)
From a Swedenborgian Christian perspective, the error of thinking about God as existing within time, and of "from eternity" as God passing through an infinity of time before creating the universe and humans in it, is the origin of errors such as the one expressed in the quote from G.K. Chesterton in the question, in which the solution to God's love before the creation of the universe is the different members of the Trinity of Persons loving one another during that supposed eternity of time before the moment of creation.
Once we understand that the being of God exists outside of time and space, and is not subject to the passage of time, these errors fall away, and we can think clearly about the nature of God, and of God's love. Here is how Swedenborg expresses this resolution to the problem of God, time, and eternity:
We cannot say that the creation of the universe and everything in it happened from one place to another or from one moment in time to another, that is, gradually and sequentially. We must say that it happened from eternity and from infinity, and not from an eternity of time, since there is no such thing, but from a nontemporal eternity that is the same as Divinity, and not from an infinity of space, since there is no such thing, but from a nonspatial infinity that is also the same as Divinity.
I know that all this transcends any mental images that arise in physical light, but they do not transcend mental images that arise in spiritual light. There is no trace of space and time in these latter images. Actually, this does not completely transcend images that arise in physical light, since everyone would agree on the basis of reason that there is no such thing as an infinity of space. The same holds for eternity, which is an infinity of time. If you say "to eternity," this can be understood in temporal terms; but if you say "from eternity," that is incomprehensible unless you banish time. (Divine Love and Wisdom #156)
Difficulties with passages such as John 14:31 and John 17:24 also vanish if we lift our minds above time and space, and thereby above the materialism and literalism that has taken hold in much of Christianity today, and read these passages metaphorically and spiritually. In particular, the love that existed between the Father and the Lord before the beginning of the world was the union of the Divine Love and the Divine Wisdom in God. But explaining this from a Swedenborgian perspective would expand this answer past the character limits of this website. For that, I highly recommend that you read Swedenborg's great cosmological, philosophical, and theological work, Divine Love and Wisdom. (The link is to a notice for this book on my website. It provides links for purchasing or freely downloading the book in the newest and most readable translation.)
For God, eternity is not an eternity of time, but an eternity of state
Here is how Swedenborg says this, in a briefer version of the experience quoted above from True Christianity #31:
Since angels have no notion of time, they have a different concept of eternity than we earthly people do. By "eternity," angels perceive an infinite state, not an infinite time.
I was thinking about eternity once, and using a concept of time I could grasp what "to eternity" entailed—namely, without end—but not what "from eternity" entailed and therefore not what God did before creation, from eternity. As my anxiety mounted because of this, I was raised into the sphere of heaven and therefore into the perception of eternity shared by angels. This shed light for me on the fact that we ought not to think about eternity in temporal terms but in terms of state, and that when we do, we can grasp what "from eternity" entails, which was actually done for me. (Heaven and Hell #167, emphasis added)
Since we humans on earth do think in terms of time in almost everything we think about or do, it is not easy for us to lift our minds above time so that we can understand what an "eternity of state" is. According to Swedenborg, angels have an easier time grasping this:
People inevitably confuse Divine Infinity with infinity of space. And because they do not conceive of infinity of space as anything other than nothingness, as indeed it is, neither do they believe in Divine Infinity. The same applies to Eternity. They cannot conceive of it except as an eternity of time, but it is manifested continually by means of time to those who dwell within [space and] time. The true idea of Divine Infinity is instilled into angels by their being instantaneously under the Lord's view with no intervening space or time even if they came from the ends of the universe. And the true idea of Divine Eternity is instilled into them by the fact that thousands of years do not appear to them as a period of time, almost as if they had lived for only a minute. Both ideas are also instilled by means of the fact that the present with them includes past and future together. Consequently they have no anxiety about things of the future, nor do they ever have any idea of death, but only of life. And so their whole present includes within it the Lord's Eternity and Infinity. (Arcana Coelestia #1382)
We humans on earth can gain some sense of what "eternity of state" means by the common experience that "time flies when you're having fun." When we are fully engaged in something we love to do, time almost disappears for us, as we are caught up in the flow of our enjoyable experience. Only when we come out of it do we suddenly realize that four or five hours have gone by in what felt to us like a few minutes. That's because we were in a state of love and enjoyment of what we were doing.
If we extrapolate this upward to the being of God, we can gain some sense of how God could see all of time and space in one present view. For God, there is no such thing as past, present, and future. Nor is there any such thing as near and far. Rather, God sees all of it from an eternal "Now" that is completely beyond our human, material experience of time and space. God's love is everywhere all at once. That's why God sees everything everywhere all at once, with no sense of time whatsoever.
For God, there is never a "time" when there is no one to love
Because God exists outside of time, and sees all time and space in a single view, similar to our seeing the whole expanse of a country laid out in one view on a map, there never was, isn't now, and never will be a "time" when there is no one to love. For God, all human beings who have ever existed and ever will exist are a present reality. God, from God's eternity of state, is present in that eternal Now with all people, in all places and times.
This means that God "always" has people (and animals, and plants, and inanimate objects) to love. For God, there is never a "time" when there is no one to love, because for God, there is no time.
Love is God's substance and God's life
As noted in the question, 1 John 4:8 (and 1 John 4:16) tells us that "God is love."
Swedenborg takes this quite literally. Divine love, he says, is the substance of God, whereas divine wisdom, or divine truth, is the form of God.
Because love is God's substance and God's life, love is also our substance and our life as human beings. Here is how Swedenborg expresses this:
Love is our life. For most people, the existence of love is a given, but the nature of love is a mystery. As for the existence of love, this we know from everyday language. We say that someone loves us, that monarchs love their subjects, and that subjects love their monarch. We say that a husband loves his wife and that a mother loves her children, and vice versa. We say that people love their country, their fellow citizens, their neighbor. We use the same language about impersonal objects, saying that someone loves this or that thing.
Even though the word "love" is so commonly on our tongues, still hardly anyone knows what love is. When we stop to think about it, we find that we cannot form any image of it in our thoughts, so we say either that it is not really anything or that it is simply something that flows into us from our sight, hearing, touch, and conversation and therefore influences us. We are wholly unaware that it is our very life—not just the general life of our whole body and of all our thoughts, but the life of their every least detail. Wise people can grasp this when you ask, "If you take away the effects of love, can you think anything? Can you do anything? As the effects of love lose their warmth, do not thought and speech and action lose theirs as well? Do they not warm up as love warms up?" Still, the grasp of these wise people is not based on the thought that love is our life, but on their experience that this is how things happen. (Divine Love and Wisdom #1)
A few sections later, he applies this to God as both the being and the source of all life:
God alone—the Lord—is love itself, because he is life itself. Both we on earth and angels are life-receivers. (Divine Love and Wisdom #4)
Real love is giving to others from ourselves and feeling others' joy as our own, and the interpersonal union that comes from these
Moving from the abstract to the personal, though, what is love? What is love all about? Here is Swedenborg's key statement on this question:
Divine love and wisdom cannot fail to be and to be manifested in others that it has created. The hallmark of love is not loving ourselves but loving others and being united to them through love. The hallmark of love is also being loved by others because this is how we are united. Truly, the essence of all love is to be found in union, in the life of love that we call joy, delight, pleasure, sweetness, blessedness, contentment, and happiness.
The essence of love is that what is ours should belong to someone else. Feeling the joy of someone else as joy within ourselves—that is loving. Feeling our joy in others, though, and not theirs in ourselves is not loving. That is loving ourselves, while the former is loving our neighbor. These two kinds of love are exact opposites. True, they both unite us; and it does not seem as though loving what belongs to us, or loving ourselves in the other, is divisive. Yet it is so divisive that to the extent that we love others in this way we later harbor hatred for them. Step by step our union with them dissolves, and the love becomes hatred of corresponding intensity.
Can anyone fail to see this who looks into the essential nature of love? What is loving ourselves alone, really, and not loving someone else who loves us in return? This is more fragmentation than union. Love's union depends on mutuality, and there is no mutuality within ourselves alone. If we think there is, it is because we are imagining some mutuality in others.
We can see from this that divine love cannot fail to be and to be manifested in others whom it loves and who love it. If this is characteristic of all love, it must be supremely characteristic, infinitely characteristic, of love itself. (Divine Love and Wisdom #47–48)
If they take seriously their claim to believe in one God rather than in three gods, trinitarians believe that God spent eternity before Creation loving himself. Not, so, says Swedenborg! There can be no self-love in God, because very nature of love is to love others outside of oneself. If God is one God and not three gods, then God loving himself in the form of the supposed three "Persons" of God loving one another is not love at all; it is self-absorption and selfishness. The only way out of this is for trinitarians to admit that they actually do believe in three gods.
Swedenborg rejects any notion that God loving God, or one divinity loving another divinity, could be real love:
In regard to God, loving and being loved in return are not possible in the case of others who have some share of infinity or anything of the essence and life of intrinsic love or of Divinity. If there were within them any share of infinity or anything of the essence and life of intrinsic love—of Divinity, that is—it would not be others who would be loving God. He would be loving himself. What is infinite or divine is unique. If it were in others, it would still be itself; and it would be pure love for itself, of which there cannot be the slightest trace in God. This is absolutely opposite to the divine essence. For love to be mutual, then, it needs to be a love for others in whom there is nothing of intrinsic Divinity; and we will see below [55, 305] that it is a love for others who were created by Divinity.
For this to happen, though, there must be an infinite wisdom that is at one with infinite love. That is, there must be the divine love of divine wisdom and the divine wisdom of divine love discussed above (34–39). (Divine Love and Wisdom #49, emphasis added)
From a Swedenborgian Christian perspective, for God to spend any amount of time at all, let alone a supposed infinity of time before the moment of creation, wrapped up in divine love of self is utterly contrary to the outgoing, giving nature of God's love. In fact, the entire reason God created the universe was to have beings distinct from God whom God could love, could give divine gifts and blessings to, could feel their joy in God's own self, and through these things could be united with them in love. If the trinitarians were right about God's self-love from eternity, there would be no purpose for Creation, and none of us would exist.
It is precisely in the oneness of God, and in God's infinite, eternal, outgoing love that Swedenborgian Christians explain love not just as an attribute of God, but as the core being of God.
When we are able to banish time and space from our thinking of God at least enough to recognize that God exists in an eternal, infinite state that is beyond time and space, the conundrums and absurdities of God spending eternity engaged in rapturous self-love vanish. The very need for an unbiblical "three Persons" of God vanishes.
Rather, God, from an eternal and infinite state beyond time and space, is eternally present with all of Creation, and with every human being in it, in a state of divine love for all the beings whom God has created.
And whenever we humans choose to return God's love, so that we can feel the joy, delight, pleasure, sweetness, blessedness, contentment, and happiness that comes with the union of mutual love between God and God's creatures, then God's purpose for creating the universe has been fulfilled.