The section on adding files to Assets: Anvil Docs | Themes and Styling
should mention that most asset files are lazily loaded, as per: Where to store rarely used Javascript/CSS? - #11
The section on adding files to Assets: Anvil Docs | Themes and Styling
should mention that most asset files are lazily loaded, as per: Where to store rarely used Javascript/CSS? - #11
AWS Lightsail
su root -->not work
should be
sudo su
As per this post - it would be good to show that the Image module is Client side.
Use PIL for server side.
Searching for “label” brings up a load of results (see piccie below), not one of which is obviously the docs for the label component
Turns out the second one does take you there, you just wouldn’t know it from the result heading.
I think it would be more logical to show the component result first for a single word search like that. Or make it obvious which result goes to the component definition and not some other demo or walkthrough. Or at least give the result a meaningful header
I agree, the best fit is often missing in the search results and even if it’s there, it’s difficult to recognize.
Another thing about the search results that I don’t like is that if I click on one result and then go back, I don’t see the search result. I need to repeat the search so I can click on the next result.
Another thing I don’t like is that pages from the API documentation are often (always?) missing.
I usually give it one shot, and if I don’t see what I’m looking for at the top, I immediately switch to Google.
I like the results of label site:anvil.works
in Google better than the search results of label
inside Anvil.
EDIT
I just successfully used Google again with this search terms: site:anvil.works included modules
.
Searching in the docs for included modules
doesn’t find the correct page, Google shows it in the second place.
The documentation should indicate that anvil.users.AuthenticationFailed() (and maybe other exceptions?) requires a parameter.
Otherwise it raises:
TypeError: __init__() missing 1 required positional argument: 'error_obj'
Example app: Anvil | Login
Please document that DatePicker
has methods. focus()
does not show up in autocomplete, nor the documentation, but it’s there.
This applies to quite a few parameters, including background
, foreground
, and border
.
Searching for set_page
from the documentation page finds 15 pages that don’t contain the word set_page
.
Searching for site:anvil.works/docs set_page
with Google does a better job and returns the only page that actually contain set_page
.
I think the methods outlined in this docs section (as below) is may be missing from the API reference
GoogleMap.InfoWindow
Display a popup on the map at a particular position.
Properties
position
:GoogleMap.LatLng
- Specifies the position of the popup. Not required if this popup is anchored to a component (see theopen
method, below).content
:anvil.Component | string
- The content of the popup. Can be a string, or an Anvil Component.Methods
open(map, [anchor])
- Display this InfoWindow on the specified map. Ifanchor
is specified, the InfoWindow does not need to have its ownposition
property set.close()
- Hide this InfoWindow. The user can also cause this to happen by clicking the close button in the top-right of the popup.
Also please could I request this thread be pinned so it can be found easily (and yes I also now have it as a bookmark )
The example code here seems wonky to me:
@anvil.server.callable
def login_with_password(username, password):
user = app_tables.users.get(username=username)
if user is not None and \
bcrypt.hashpw(password, user['password_hash']).decode() == user['password_hash']:
anvil.users.force_login(user)
return user
Shouldn’t it be something like:
import bcrypt
@anvil.server.callable
def login_with_password(username, password):
user = app_tables.users.get(email=username)
if (user is not None) and \
bcrypt.checkpw(password.encode('utf-8'), user['password_hash'].encode('utf-8')):
anvil.users.force_login(user)
return user
else:
return None
Please could the docs include something on session_id
as per this post
More Documentation on PDFRenderer
I was looking to reduce the pdf size generated by PDFRenderer and went to the docs! The quality
optional argument looks like the worker for the job, but I am sure what the acceptable options are, based off of the docs. I found a couple of post showing different quality options I am trying, but having it explained clearly in the docs would be great!
The other options would be great to get the explanations as well.
Thank you anvil team!
See