As stated, the answer to the question has to be yes, a telescope on the Moon can have significant advantages over a telescope on Earth, because of Earth's atmosphere. That's why we have space telescopes.
However that is the wrong question. The real question is what advantages, as well as disadvantages, does a telescope on the Moon have over a telescope somewhere else in space, e.g. in Earth orbit or at a Lagrange point?
Overall, a telescope on the Moon is a terrible idea. First off, thermal control would be a nightmare. There are two week days and two-week nights, misaligning everything you might try to align in a telescope and with the swings making it extremely difficult to keep infrared sensors at cryogenic temperatures. Second, for the same reason, you only have solar power half the time. So you need to have enough batteries to stay alive for two weeks, or nuclear energy! If on batteries, you will want to conserve power exactly when you'd like to be observing more. Which brings up visibility. You can only see half the sky, and your telescope keeps getting turned towards the Sun every month whether you want it to or not. Which brings up pointing. You now have the Moon's gravity to deal with when turning your telescope. In space you have only your own inertia to deal with. Furthermore it will need to deploy itself in lunar gravity as opposed to zero gravity. And then there's the dust. Dust that gets kicked up by impacts and electrostatically, eventually covering your optics with a layer of crap.
You mentioned in a comment excluding considerations of cost, but you can never exclude that. Landing something softly on the Moon is hugely more expensive, in terms of mass and money, than putting it at a Lagrange point.
Should I go on?
The only conceivable advantages I can come up with are:
A. You have a stable surface in a vacuum on which to build a large interferometer,
B. Radio silence on the far side (but adding the complexity of requiring a relay orbiter to get the data back), and
C. Availability of raw materials.
For A, we can do the same thing in free space with precision formation flying, and then the horizon of the Moon doesn't limit your baseline distances.
For B, a radio telescope would get excellent isolation from Earth radio transmissions. However it seems that just putting your radio telescope on Earth in a valley with some mountains around you, and maybe some radio silence laws, works just dandy. You don't need the expense of a space-borne radio telescope (where such telescopes need to be ginormous.)
For C, you could extract materials from lunar regolith to make your mirrors. You could do the same from an asteroid more easily, with a wider range of asteroid types to choose from, and in lower gravity.
So yes, it would be better than Earth (for optical), but much, much worse than simply putting your telescope in space somewhere which is cheaper and easier.